Artificial intelligent assistant

Unique ways to assign P boxes to C bags? How many ways can I arrange $C$ unlabeled bags into $P$ labeled boxes such that each box receives at least $S$ bags (where C > S and C > P)? Assume that I can combine bags to fit a box. I have just learnt that there are $\binom{C-1}{P-1}$ unique ways to keep P balls into C bags. I am unable to get the answer for the above question from this explanation. For example, if there are 2 Boxes, 3 Bags and each Box should get 1 Bag, then there are two ways: (2,1) and (1,2). Could you please help me to get this? Thank you. $\quad\quad$

You already know that there are $\binom{C+P-1}{C}$ ways to arrange the $C$ bags into $P$ boxes if you ignore the requirement that each box should contain $S$ bags. (See Stars and Bars for more on that.)

To take the requirement into account, begin by first placing $S$ bags into each of the $P$ boxes, which uses $PS$ of your bags. Now, each box contains at least $S$ bags, so we are free to arrange the remaining $C - PS$ bags as we wish. That is, we wish to arrange $C - PS$ bags in $P$ boxes with no restriction on how many must be in a box (remember, we already met the requirement before we even started counting). By the previous formula, this can be done in $\binom{C - PS + P - 1}{C - PS}$ ways.

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy 58d99c37676d54e21b5e8438dfb97519