How to distribute these balls?

Juan has 4 distinct jars and a certain number of identical balls. The number of ways that he can distribute the balls into the jars such that each jar has at least one ball is 56. How many balls does he have?


The answer is 9.

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.

4 solutions

Using the stars and bars method, we essentially have an unknown number of balls, n n :

* * * * * * * * *

and we have to distribute 3 3 bars (which act as separators between the jars) in between ( n 1 ) (n - 1) spaces (because there cannot be empty jars).

An example would be like so:

*|* *|* * * *|* *

Therefore, ( n 1 ) choose 3 = 56 , so n = 9 (n - 1) \text{ choose } 3 = 56 \text{, so } n = 9 .

( ( m , n ) ) = ( n + k 1 k 1 ) \left(\left(m,n\right)\right)=\binom{n+k-1}{k-1}

( ( 5 , 4 ) ) = 56 \left(\left(5,4\right)\right)=56

Therefore, one for each jar plus five extras for a total of nine.

See also multiset number or stars and bars, which is not a reference to the CSA battle flag.

Pop Wong
May 30, 2020

Put 1 ball in each jars first, total used 4 balls.

Then there are 56 ways to put the remaining n = N-4 balls in the 4 jars.

Using the stars and bars method, putting 3 bars in n+3 slots, to distribute the remaining n balls into 4 jars.

( n + 3 3 ) = 56 ( n + 1 ) ( n + 2 ) ( n + 3 ) = 336 n + 1 = 6 {n+3 \choose 3}=56 \rightarrow (n+1)(n+2)(n+3) = 336 \rightarrow n+1=6

N = n + 4 = 9 N = n + 4 = \boxed{9}

Baozhu Liang
Jul 7, 2019

This sequence appears in Pascal's triangle

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...