To obtain the coefficient of $$x^4$$ from $$(1-x+2x^2)^5$$
let $$a+b+c=5$$ where $$a$$ copies of $$1$$,
$$b$$ copies of $$-x$$, and
$$c$$ copies of $$2x^2$$ are selected.
The power of $$x$$ contributed is $$b+2c$$
Hence we require
$$b+2c=4$$
The possible solutions are:
$$ (b,c)=(4,0) $$
$$ (b,c)=(2,1) $$
$$ (b,c)=(0,2) $$
For
$$ (b,c)=(4,0) $$
we have
$$a=1$$
Contribution
$$=\frac{5!}{1!4!0!}(-1)^4$$
$$=5$$
For
$$ (b,c)=(2,1) $$
we have
$$a=2$$
Contribution
$$=\frac{5!}{2!2!1!}(-1)^2(2)^1$$
$$=30\times2$$
$$=60$$
For
$$ (b,c)=(0,2) $$
we have
$$a=3$$
Contribution
$$=\frac{5!}{3!0!2!}(2)^2$$
$$=10\times4$$
$$=40$$
Therefore the coefficient of
$$x^4$$
is
$$5+60+40$$
$$=105$$
Final Answer :
$$105$$