I have 4 students: Alice, Bob, Carol, and David.
I have given Alice 1 candy, Bob 2 candies, Carol 3 candies, and David 4 candies.
In how many other ways could I have distributed the 10 candies among them such that each student received at least one candy?
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Classic stars and bars problem. If there were to be no restriction on how many candies each person would receive, there would be ( 3 1 3 ) ways to distribute the candy. Factoring in the one candy restriction, there are now ( 3 9 ) = 6 ! ∗ 3 ! 9 ! = 8 4 ways to distribute the candy. Given that the problem gave one way the candy could be distributed, we are counting all other ways it could be distributed. Therefore the answer is 8 4 − 1 = 8 3