Solution
Stars and Bars
Show the problem again
How many solutions in nonnegative integers does x₁ + x₂ + x₃ + x₄ = 10 have?
Worked solution
The answer is 286. Represent each solution as 10 stars separated into 4 groups by 3 bars: a sequence of 13 symbols where we choose the bars' positions. The count is C(13, 3) = 286. In general, x₁ + ... + x_k = n has C(n + k − 1, k − 1) nonnegative solutions.
Source: The stars-and-bars argument, popularised by William Feller, 'An Introduction to Probability Theory and Its Applications' (1950). Statement written for AxiomIQ.