Find the coefficient of $x^{18}$ in $(x + x^2 + x^3 + x^4 + x^5)(x^2 + x^3 + x^4 +\cdots)^5 $ 
Find the coefficient of $x^{18}$ in $$(x + x^2 + x^3 + x^4 + x^5)(x^2 + x^3 + x^4 +\cdots)^5 $$

This is the first time coming across a generating function question and am not quite sure how to solve this and am looking for some help, thanks!

You can rewrite your expression as $x^{11}(1+x+x^2+x^3+x^4)(1+x+x^2+x^3+x^4+\ldots)^5$ so you are looking for the coefficient of $x^7$ in $$(1+x+x^2+x^3+x^4)(1+x+x^2+x^3+x^4+\ldots)^5$$  This is the number of ways to write $7$ as the sum of six nonnegative integers with the first being at most four.  Stars and bars gives you the number without the restriction on the first as ${12 \choose 5}$.  Now subtract off the number of ways to express $2,1,0$ as five nonnegative integers, so we have $${12 \choose 5}-{6 \choose 4}-{5 \choose 4}-{4 \choose 4}$$
