In a right angle, the sum of the squares of the two shorter sides is equal to the square of the longest side.
Here, the longest side is 25, the shorter sides are x and x+5.
[tex]x^2+(x+5)^2=25^2 \\
x^2+x^2+10x+25=625 \\
2x^2+10x+25=625 \ \ \ |-625 \\
2x^2+10x-600=0 \ \ \ |\div 2 \\
x^2+5x-300=0 \\
x^2+20x-15x-300=0 \\
x(x+20)-15(x+20)=0 \\
(x-15)(x+20)=0 \\
x-15=0 \ \lor \ x+20=0 \\
x=15 \ \lor \ x=-20
[/tex]
The length of a side must be a positive number, so x=15.
The answer is C.