In short
Division splits a set of objects into groups. Distribution places objects into labelled containers. When the objects are distinct, each distribution is a sequence of combinations. When the objects are identical, the problem reduces to counting solutions of x_1 + x_2 + \dots + x_k = n in non-negative integers, solved by the stars and bars formula \binom{n + k - 1}{k - 1}. Equal-sized groups need a correction factor to avoid overcounting, and the size of that factor depends on whether the groups themselves are distinguishable.
You have 12 ladoos and 3 children — Aarav, Bhumi, and Chirag. You want to give all 12 ladoos away, with each child getting at least one. The ladoos are identical (each one tastes the same), and the children are distinct (Aarav is not Bhumi). How many ways can you distribute them?
This is a fundamentally different question from "how many ways can you arrange 12 objects" or "how many ways can you choose 3 from 12." Here the core operation is splitting a collection into parts, and the answer depends on two things: whether the objects are distinguishable from each other, and whether the groups (or containers) are distinguishable from each other.
This article covers all four combinations of those two binary choices.
Distinct objects into distinct groups (labelled boxes)
This is the most common distribution scenario on exams: n distinct objects placed into k distinct groups, with specified group sizes.
Fixed group sizes. If the groups must have sizes r_1, r_2, \ldots, r_k (where r_1 + r_2 + \cdots + r_k = n), the count is the multinomial coefficient:
Multinomial coefficient
The number of ways to divide n distinct objects into k ordered groups of sizes r_1, r_2, \ldots, r_k (with r_1 + r_2 + \cdots + r_k = n) is:
The reasoning: choose r_1 objects for the first group from n (\binom{n}{r_1} ways), then r_2 for the second from the remaining n - r_1 (\binom{n - r_1}{r_2} ways), and so on. Multiply:
The cancellation is clean: each successive binomial coefficient's denominator absorbs the previous remainder's factorial.
Division into equal groups — the overcounting trap
When k groups all have the same size r (so n = kr), the multinomial coefficient \frac{n!}{(r!)^k} counts divisions into labelled groups — Group 1, Group 2, and so on. If the groups are unlabelled (indistinguishable — no names, no ordering), then every set of k groups has been counted k! times (once for each permutation of the group labels). Divide by k!:
This correction factor is the single most-tested subtlety in division problems.
When to divide by k! and when not to:
- Groups are labelled (Team A, Team B, Team C; or the groups go to different destinations): do not divide by k!.
- Groups are unlabelled (split into k piles for no particular reason): divide by k!.
The distinction: if swapping two groups gives a different outcome (because the groups have names or destinations), the groups are labelled. If swapping changes nothing, they are unlabelled.
Mixed sizes. If the groups have unequal sizes, there is no overcounting from group labels (because the sizes themselves distinguish the groups). But if some groups happen to share the same size — say, 2 groups of size 3 and 1 group of size 4 — you divide only by the factorial of the number of groups that share each size. For 2 groups of size 3: divide by 2! for those two.
Distribution of distinct objects — no size constraint
If n distinct objects are distributed into k distinct boxes with no restriction on how many go in each box (a box can be empty), each object independently chooses one of k boxes. The total count is:
This is the multiplication principle: n independent choices, each with k options.
If each box must be non-empty (every child must get at least one ladoo), the count is more involved and uses the inclusion-exclusion principle. The formula involves the Stirling numbers of the second kind, but for most school-level problems, case splitting by group sizes (using the multinomial coefficient) is the standard approach.
Identical objects into distinct groups — stars and bars
This is where the ladoo problem lives. You have n identical objects and k distinct groups (children, boxes, containers). The question is: how many ways to distribute n identical items into k distinct bins?
Each distribution corresponds to a solution of:
where x_i is the number of objects in bin i.
Stars and bars (non-negative version)
The number of ways to distribute n identical objects into k distinct bins (each bin may be empty) equals the number of non-negative integer solutions of x_1 + x_2 + \cdots + x_k = n:
Why the formula works
Picture the n objects as n stars (\star) in a row. To divide them into k groups, you need k - 1 dividers (bars, |) placed among the stars. Everything to the left of the first bar goes to bin 1, everything between the first and second bar goes to bin 2, and so on.
For n = 5 stars and k = 3 bins, one arrangement is:
This represents x_1 = 2, x_2 = 1, x_3 = 2. Another arrangement:
This represents x_1 = 0, x_2 = 5, x_3 = 0. Bars can be adjacent (giving empty bins) or at the ends.
The total number of symbols is n + k - 1 (stars plus bars). You choose k - 1 positions for the bars (the rest are stars). The count is:
Equivalently, you can choose n positions for the stars: \binom{n + k - 1}{n}. By the symmetry property of combinations, these are the same number.
Stars and bars with a minimum: x_i \geq 1
If every bin must receive at least one object, substitute y_i = x_i - 1 (so y_i \geq 0). The equation becomes:
Apply the standard formula with n - k in place of n:
So the number of ways to distribute n identical objects into k distinct non-empty bins is \binom{n-1}{k-1}.
Back to the ladoo problem: 12 identical ladoos distributed among 3 children, each child getting at least one.
There are 55 ways. If empty plates were allowed, the count would be \binom{14}{2} = 91.
Identical objects into identical groups — partitions
When both the objects and the groups are indistinguishable, the question becomes: in how many ways can the integer n be written as a sum of k positive integers (where order does not matter)? This is the partition of n into k parts.
There is no closed-form formula for partitions. You count them by listing or by recursive methods.
For n = 7 into k = 3 positive parts (order does not matter):
That gives 4 partitions. There is no shortcut — you simply enumerate the possibilities, starting with the largest possible first part and working downward systematically.
Two worked examples
Example 1: In how many ways can $10$ identical chocolates be distributed among $4$ children such that each child gets at least $2$?
Step 1. Set up the equation.
Let x_i be the number of chocolates child i receives. The constraint is:
Why: identical objects distributed among distinct recipients is a stars-and-bars problem, and the "at least 2" constraint sets a lower bound on each variable.
Step 2. Substitute to remove the lower bound.
Let y_i = x_i - 2, so y_i \geq 0. Then:
Why: giving each child the minimum of 2 uses up 4 \times 2 = 8 chocolates, leaving 2 to distribute freely.
Step 3. Apply the stars-and-bars formula.
Why: 2 identical stars placed among 3 bars give \binom{5}{3} arrangements.
Step 4. List all solutions to verify.
The non-negative integer solutions of y_1 + y_2 + y_3 + y_4 = 2:
(2,0,0,0) and its 4 permutations → 4 solutions (1,1,0,0) and its \binom{4}{2} = 6 permutations → 6 solutions
Total: 4 + 6 = 10. This matches.
Why: the direct enumeration confirms the formula. Each solution here translates to an (x_1, x_2, x_3, x_4) by adding 2: for example, (y_1, y_2, y_3, y_4) = (2, 0, 0, 0) gives (4, 2, 2, 2).
Result. \binom{5}{3} = 10 distributions.
The enumeration confirms the formula: 4 solutions of type (2, 0, 0, 0) plus 6 solutions of type (1, 1, 0, 0) gives 10, exactly \binom{5}{3}.
Example 2: Divide $8$ students into two groups of $4$ to play a practice match. How many ways?
Step 1. Treat the groups as labelled first.
Choose 4 students from 8 for Group 1; the remaining 4 automatically go to Group 2.
Why: the multinomial coefficient \frac{8!}{4!\,4!} counts divisions into two labelled groups of 4.
Step 2. Check: are the groups labelled or unlabelled?
The problem says "divide into two groups" — no names, no "batting first" or "fielding first." The groups are unlabelled.
Why: if Group 1 = {Aarav, Bhumi, Chirag, Divya} and Group 2 = {Esha, Farhan, Gauri, Harsh} is the same partition as Group 1 = {Esha, Farhan, Gauri, Harsh} and Group 2 = {Aarav, Bhumi, Chirag, Divya}, then you are overcounting by a factor of 2!.
Step 3. Correct for overcounting.
Why: every partition was counted 2! = 2 times (once with each labelling of the two groups), so dividing by 2 gives the true count.
Step 4. Sanity check.
If the groups had different sizes — say, 3 and 5 — no correction would be needed, because the sizes themselves distinguish the groups. The correction factor k! applies only to groups of equal size.
Result. 35 ways to split 8 students into two equal groups.
If the two groups were assigned to bat first and field first (labelled), the answer would stay at 70 — the labels prevent the overcounting.
Common confusions
-
"Stars and bars works for distinct objects." It does not. Stars and bars counts distributions of identical objects — the stars are indistinguishable. For distinct objects, use the multinomial coefficient or the multiplication principle (k^n for unrestricted placement).
-
"I always divide by k! when dividing into groups." Only when the groups are unlabelled and of equal size. If the groups have different sizes, the sizes already distinguish them. If the groups have labels (destinations, team names), do not divide by k!.
-
"\binom{n+k-1}{k-1} allows negative values in the bins." The derivation assumes x_i \geq 0. If you need x_i \geq 0 but also x_i \leq c (an upper bound), the formula does not apply directly — you need inclusion-exclusion to subtract the cases where some x_i exceeds c.
-
"The number of partitions of n into k parts has a closed-form formula." It does not. Integer partitions have no simple closed form; they are computed by enumeration or generating functions. The stars-and-bars formula applies to compositions (ordered) of n, not to partitions (unordered).
-
"Distributing n objects into k boxes where each box gets at least one is \binom{n-1}{k-1} regardless of whether the objects are distinct or identical." The formula \binom{n-1}{k-1} is for identical objects. For distinct objects, the count is a surjection count involving inclusion-exclusion — a much harder problem.
Going deeper
If you can apply the multinomial coefficient, the stars-and-bars formula (both the \geq 0 and \geq 1 versions), and the equal-group correction, you have the tools for the vast majority of exam problems on division and distribution. The rest of this section is for readers who want to see the connection to generating functions and the general upper-bounded case.
Stars and bars with upper bounds
What if each bin has a maximum capacity? Suppose x_1 + x_2 + x_3 = 10 with 0 \leq x_i \leq 5. The unconstrained count is \binom{12}{2} = 66. But some solutions have x_i > 5, which violates the cap.
Use inclusion-exclusion. Let A_i be the set of solutions where x_i > 5, i.e., x_i \geq 6. Substitute x_i = 6 + y_i (with y_i \geq 0) to get a new equation y_i + (\text{other variables}) = 4, which has \binom{6}{2} = 15 solutions. Since there are 3 variables:
Can two variables simultaneously exceed 5? That would require x_i \geq 6 and x_j \geq 6, meaning their sum alone is \geq 12 > 10. So |A_i \cap A_j| = 0 for all pairs.
By inclusion-exclusion: valid solutions = 66 - 45 + 0 = 21.
This technique generalises: for any upper bound c on each variable, substitute x_i = c + 1 + y_i to count violations, and use inclusion-exclusion to subtract them.
Compositions and weak compositions
A composition of n into k parts is a solution of x_1 + x_2 + \cdots + x_k = n with x_i \geq 1 (order matters). The count is \binom{n-1}{k-1}.
A weak composition allows x_i = 0 as well. The count is \binom{n+k-1}{k-1}.
Compositions are essentially the "stars and bars" distributions with the positivity constraint, viewed through a number-theory lens rather than a combinatorics lens. The generating function for the number of compositions of n into any number of parts is:
because there are 2^{n-1} compositions of n (each of the n-1 gaps between consecutive units is either a separator or not). This bridges the counting techniques of this article with the algebraic methods of generating functions that appear in more advanced combinatorics.
Where this leads next
Division and distribution problems combine the techniques from across combinatorics.
- Combinations — Basics — the formula \binom{n}{r} is the engine behind every calculation in this article.
- Properties of Combinations — the identities that simplify multinomial coefficient computations.
- Combinations with Restrictions — forced inclusion/exclusion and complement counting, which appear in upper-bounded distribution problems.
- Permutations — Special Cases — permutations of objects that are not all distinct, closely related to the multinomial coefficient.
- Fundamental Principle of Counting — the multiplication and addition principles that justify every case split and every product formula in this article.