Ravi V. answered 05/14/17
Tutor
5.0
(47)
Will teach you how to learn Math
I don't know if it is OK to put links here or not, but look up "stars and bars" theorem or method, you will find explanation of how the formula is derived. But basically the formula is this:
To place n balls in k boxes you can do in
(n+k-1)
C
(k-1)
ways. Since each box should contain at least one ball, our problem reduces to placing the rest of the 6 balls in 4 boxes after placing 1 each in each of the boxes. Using the formula you get
(6+4-1) choose (4-1) ways or
9C3 ways. = 9!/(6!3!) ways