We consider a system composed of a fixed number of particles with total energy smaller or equal to some prescribed value. The particles are non-interacting, indistinguishable and distributed over fixed number of energy levels. The energy levels are degenerate and degeneracy is a function of the number of particles. Three cases of the degeneracy function is considered. It can increase with either the same rate as the number of particles or slower, or faster. We find useful properties of the entropy of the system and solve related entropy optimization problem. It turned out, there are several solutions. Depending on the magnitude of total energy, the maximum of the entropy can be in the interior of system’s state space or on the boundary. On the boundary it can have further three cases depending on the degeneracy function. The main result, Law of Large Numbers yields the most probable state of the system, which equals to the point of maximum of the entropy. This point can be either Maxwell–Boltzmann statistics or Bose–Einstein statistics, or Zipf–Mandelbort law. We also find the limiting laws for the fluctuations. These laws are different for different cases of the entropy’s maximum. They can be mixture of Normal, Exponential and Discrete distributions. Explicit rates of convergence of moment generating functions are provided for all the theorems. The overview of possible applications is provided in the last section.