A perfect square trinomial has the next general form:
[tex]a^2-2ab+b^2=(a-b)^2[/tex]The term 2ab in the given equation is: 10x or 2(5)x
Then:
[tex]\begin{gathered} 2ab=2\cdot5x \\ 2=2 \\ a=x \\ b=5 \end{gathered}[/tex]Then, to becomes the given binomial into a perfect sqare trinomial you add b squared, you get:
[tex]\begin{gathered} x^2-10x+5^2 \\ x-10x+25 \end{gathered}[/tex]Then, the constant you add is 25