0

If i want to distribute n chocolates to m friends considering each friend can get 0 to n chocolates(unfair distribution is possible), how many ways can i do it?

KenAdams
  • 103

1 Answers1

0

Here's one way to break down the problem.

First consider the number of ways that you can divide up $n$ chocolates into $1 ... k$ groups, where $k$ is the lesser of $m$ and $n$. (Assuming that you cannot give less than one full chocolate to anyone.)

This gives you groups of chocolates on the table. Your friends haven't arrived yet.

Once you have that, consider the number of ways that you can distribute those groups to your $m$ friends when they stop by.

For example, for one grouping, you have divided eight chocolates into five groups: three groups of $1$, one group of $2$, and one group of $3$.

Your seven friends come over for a chocolate-eating party. Any one of the seven can grab the three-chocolate group. Any one of the remaining six can grab the two-chocolate group.

Three of the remaining five can grab the last three one-chocolate groups, but there are only $_5C_3 = 10$ ways they can do this if the chocolates are all the same.

Hope that helps.

John
  • 26,319