Let $G(x) = \frac{1}{(1-x)^2} = \sum\limits_{i=0}^\infty g(i)x^i$, where $|x| < 1$. What is $g(i)$?
Why don't use the same method?
https://en.wikipedia.org/wiki/Taylor_series
https://gateoverflow.in/88476/generating-function
Option B) is the answer
@rawan Check this out.