Counting ways to distribute n identical objects among r groups can be found using:
$C(n + r - 1, r - 1)$
or
$C(n + r - 1, n)$
However, I can't work out how to approach answering this question when it specifies up to $n$ identical objects being distributed rather than exactly $n$. In other words, some objects can be left over or not distributed.
This is $\sum_{k=0}^n\binom{k+r-1}{r-1}=\binom{n+r}r$, the hockey stick identity. The simple result suggests that there must be a simple combinatorial proof, and indeed there is: Introduce an $(r+1)$-th group and distribute the remaining objects to it.