24. Each of the numbers $m$ and $n$ is the square of an integer. The difference $m-n$ is a prime number.
Which of the following could be $n$ ?
A 100
B 144
C 256
D 900
E 10000
Solution
D

Since $m$ and $n$ are squares, we can write $m=x^{2}$ and $n=y^{2}$ for some positive integers $x$ and $y$. Then the difference is $m-n=x^{2}-y^{2}=(x+y)(x-y)$. But $m-n$ is prime and has only two factors ( 1 and itself). Hence $x-y=1$ and $x+y$ is prime. Rearranging $x-y=1$ gives $x=y+1$, so $x+y=2 y+1$ is prime. For the options available for $n=y^{2}$, the values of $y$ are $10,12,16,30,100$ and $2 y+1$ is $21,25,33,61,201$ respectively. The only prime in this list is 61 , so $y=30$ and $n=30^{2}=900$.