Hello , please guide me .

How can I transformed the equation to ?

I studied a lecture that the writer had written :<< by using we can transformed to But how ? if in we obtain by we will have : and if we substitute in we don't have $y^5+2y^2+47y+122$ . please explain it.

Thank you very much