There isn't really any theorem. Just note $p + 1 =k^2$ and hopefully you'll realize that that means $p = k^2 -1$ and it'll put you in mind of attempting to factor $k^2 - 1$ and seeing what conditions are required if $p$ is prime.
– fleabloodJun 14 '18 at 05:11
1 Answers1
4
If $p+1$ is a perfect square, we have $p+1 = n^2$ i.e., $p = n^2-1 = (n+1)(n-1)$.
If $n>2$ then $n-1$ $> 1$ i.e., p is not a prime.
Thus, the only case where $p+1$ can be a perfect square is if $n = 2$
i.e., $p = 3.$