So I have this homework question I've been trying all day to answer, any help would be appreciated:
Determine using generating functions in how many ways can you choose $3n$ letters out of $\{a, b, c\}$ so that each letter is chosen at most $2n$ times?
You can start with the generating function $\displaystyle(1+x+x^2+\cdots+x^{2n})^3=\bigg(\frac{1-x^{2n+1}}{1-x}\bigg)^3$, and then find the coefficient of $x^{3n}$ using the formula $\displaystyle (1-x)^{-3}=\sum_{n=0}^{\infty}\binom{n+2}{2}x^n$.