<s>[INST] Find all primes $p$ such that $ p^3-4p+9 $ is a perfect square. 
Find all primes $p$ such that  $ p^3-4p+9 $ is a perfect square.

I tried a few different values for $p$, namely $2,3,5,7,$ and $11$. The prime $p =2,7,11$ all worked but $p =13$ didn't so it makes me wonder. How can I find all primes such that it is a perfect square?
EDIT: it turns out this is problem P25 in post number #63 at http://artofproblemsolving.com/community/c3h1171106p5665470
 [/INST] If $p^3-4p+9=n^2$ then $n^2\equiv 9 \pmod{p}$ and $\pm n \equiv 3 \pmod{p}$ since $n^2-9\equiv 0$ can only have two roots modulo a prime.
By choosing the appropriate sign we can write
$$
\begin{align}
n^2=(-n)^2 &= (kp+3)^2 \\
p^3-4p+9 &= k^2p^2+6kp+9 \\
0 &= p^2-k^2p-(6k+4) \\
p & = \frac{k^2\pm \sqrt{k^4+24k+16}}{2}
\end{align}
$$
where we used $p\ne 0$ since it's a prime. This can only have an integer solution for $p$ when $k^4+24k+16$ is a square (as @tkr suggested in the comments).
But
$$
\begin{array}{ll}
(k^2-1)^2 = k^4-2k^2+1 < k^4+24k+16<(k^2)^2 & \text{if }k<-11 \\
(k^2)^2 < k^4+24k+16< k^4+2k^2+1 =(k^2+1)^2 & \text{if }k>12
\end{array}
$$
so if $k<-11$ or $k>12$ then $k^4+24k+16$ lies between two squares and hence is not a square. This leaves 24 values to check, which you could do by hand. It leads to solutions when $k=-3,0,3$ which give integral values for $p$ of $-2,2,7,11$, of which only $2,7,11$ would normally be considered prime.
</s>