Answer :
Since x=1 is a root of multiplicity 2 and x= -2 is a root with multiplicity 1, our polynomial has the form
[tex]f(x)=A\cdot(x-1)^2\cdot(x+2)[/tex]where A is an unknown constant.
We can find A by substituting into our last result the given point (0,4), that is,
[tex]4=A\cdot(0-1)^2\cdot(0+2)[/tex]which gives
[tex]\begin{gathered} 4=A\cdot(-1)^2\cdot2 \\ \text{then} \\ 4=A\cdot1\cdot2 \\ so \\ 4=2A \end{gathered}[/tex]then, by dividing both sides by 2, we get
[tex]A=2[/tex]Therefore, the answer is:
[tex]f(x)=2(x-1)^2(x+2)[/tex]