Finding solutions for expression to be a perfect square
An alternative solution ...
We have $n^4-n^2+64=A^2$. Multiply this by $4$ and complete the square $(2n^2-1)^2+255=4A^2$. So
\begin{eqnarray*}
(2A+2n^2-1)(2A-2n^2+1)= 3 \times 5 \times 17.
\end{eqnarray*}
This gives
\begin{eqnarray*}
2A+2n^2-1 = x \\
2A-2n^2+1= y
\end{eqnarray*}
There are $4$ possible values for $(x,y)$ ... $(15,17),(17,15),(51,5),(85,3),(255,1)$. These lead to $(A,n^2)$ having the values $(8,0),(8,1),(14,12),(22,21),(64,64)$. The first second and last will give valid answers $\color{red}{n=0}$, $\color{red}{n= \pm 1}$ and $\color{red}{n= \pm 8}$.
If ( with integer $a \geq 1$) $$ (a-1)^2 < w < a^2, $$ then $w$ is not a square at all. I guess I can add that then $$ a-1 < \sqrt w < a, $$ so that $\sqrt w$ is not an integer, it lies strictly between two consecutive integers.
As usual, there are a few cases to check for small $w$
You are given $n^4 - n^2 + 64.$ Now, $(n^2)^2 = n^4.$ Also $(n^2 - 1)^2 = n^4 - 2 n^2 + 1.$
For $n \geq 9$ we have $n^2 > 64$ so that $n^4 - n^2 + 64 < n^4.$
For $n \geq 8,$ $$ n^4 - n^2 + 64 - (n^2 - 1)^2 = n^2 - 63 > 0, $$ so $$ n^4 - n^2 + 64 > (n^2 - 1)^2. $$
Alrighty, for $n \geq 9 $ we get $$ (n^2 - 1)^2 < n^4 - n^2 + 64 < (n^2)^2 $$ so that $n^4 - n^2 + 64$ is NOT a square for $n \geq 9.$
You still need to check $n=0,1,2,3,4,5,6,7,8.$
Following the author's solution, since $n^4-n^2+64>(n^2-1)^2$ any $n^4-n^2+64$ which equals a square can be written as $(n^2+k)^2$ for $k$ a non-negative integer (i.e. $k>-1$ in the $(n^2-1)^2$). That means $$n^4-n^2+64 = n^4+2kn^2+k^2$$ and $$n^2=\frac{64-k^2}{(2k+1)}.$$ We need to check for $0\leq k\leq 8$ (since $n^2>0$) to see which values are squares, and find only $k=0, 7$ and $8$ work giving us the solutions $n=0, n=\pm1$, and $n=\pm8$.