I'm working through my Combinatorics textbook and am stuck on this proof. The textbook explains it pretty well, but I am having trouble with one of the steps. I was hoping I could get some help here
Theorem: If A(x) and B(x) are formal power series and the constant term of B(x) is zero, then A(B(x)) is a formal power series.
Proof:
Let $A(x) = a_0 + a_1x + a_2x^2 + ....$ and $B(x) = xC(x)$ This is so that B(x) has no constant term
$$A(B(x)) = A(xC(x))$$ $$= a_0 + a_1xC(x) + a_2x^2(C(x))^2 + ...$$
For each $k \gt 0$, $a_kx^kC(x)^k$ is a formal power series since it is the product of formal power series. Also, for each $m \lt k$, $[x^m](a_kx^kC(x))^k = 0$. This is because when $x^k$ is distributed into $C(x)^k$, the smallest degree of x will be k, so all coefficients of powers of x less than k will be 0. This next part is where I'm lost
Therefore $$[x^n]A(B(x)) = [x^n](a_0 + a_1xC(x) + a_2x^2C(x)^2 + ...)$$ $$= [x^n](a_0 + a_1xC(x) + a_2x^2C(x)^2 + ... + a_nx^nC(x)^n)$$
I don't understand how we could have gone from the first line to the second. Could someone please be kind enough to explain this to me? I have a feeling it's simple, but for some reason I just can't see it.
Thanks