Evochkimov M.A.

Vasya was given a quadratic equation $x^{2}+p_{1} x+q_{1}=0$ for homework, where $p_{1}$ and $q_{1}$ are integers. He found its roots $p_{2}$ and $q_{2}$ and wrote a new equation $x^{2}+p_{2} x+q_{2}=0$. Repeating the operation three more times, Vasya noticed that he had solved four quadratic equations, each with two distinct integer roots (if one of the two possible equations had two distinct roots, Vasya always chose it, and if both did, he chose any one). However, no matter how hard Vasya tried, he could not form a fifth equation that would have two distinct real roots, and Vasya became very upset. What equation was Vasya given for homework?
The fifth equation with integer coefficients should not have distinct real roots. Therefore, if its coefficients are denoted by $p_{5}$ and $q_{5}$, then $p_{5}^{2} \leq 4 q_{5}$ and $q_{5}^{2} \leq 4 p_{5}$. Both numbers are positive, and by squaring the first inequality and substituting the condition from the second, we get $p_{5}^{4} \leq 64 p_{5}$. From this, both numbers are less than 5, and by enumeration, we find the only suitable pair: 1 and 2.

The coefficients of the fifth equation found are the roots of the fourth equation; by Vieta's theorem, we find the fourth equation itself: $x^{2}-3 x+2=0$. Continuing to apply Vieta's theorem, we sequentially find the third, second, and finally the first equations: $x^{2}+x-6=0, x^{2}+5 x-6=0$,

$x^{2}+x-30=0$

## Answer

$x^{2}+x-30=0$