Given an unlimited supply of balls of n different colors and
Given an unlimited supply of balls of n different colors and a prime number p. show that the number of different arrangements of p balls in a circle is exactly (np - n) / p if we exclude the arrangements in which all the balls are the same color. Specially address why p must be prime. This proves that p divides np - n which is Fermat\'s little theorem
Solution
Given that there are n different colors and number of balls is p.
So, the number of different arrangements of p balls in n different colours is equal to np.
when we exclude the arrangements in which all the balls are the same color is n
the number of different arrangements of p balls in a circle
(np-n)/p
