When is $k^4-24k+16$ a perfect square. When is the equation $k^4-24k+16$ perfect square.
(k is an  integer.)
I got this equation as discriminant while solving an equation. I tried to solve it but couldn't i tried to write it in a form of a square but couldnt solve it.I bashed a bit and found 0 and 3 as a solution. Any help would be appreciated. Thanks in advance.

I think this is a correct solution. Suppose that $k^4-24k+16$ is a square.

*

*Suppose that $-24k+16\ge 0$. Then $k^4-24k+16\ge (k^2+1)^2=k^4+2k^2+1$, so $-24k+16\ge 2k^2+1$ or $2k^2+24k-15\le 0$ or $k^2+12k-7.5\le 0$. This means $$-6-\sqrt{36+7.5}\le k\le -6+\sqrt{36+7.5}.$$
Which means $-13\le k\le 0$ (remember that $-24k+16>0$). Checking all these $k$ we get that only $k=-3,0$ are good.


*Suppose that $-24k+16<0$ (in particular $k\ge 0$). Then $k^4-24k+16\le (k^2-1)^2=k^4-2k^2+1$, so $2k^2-24k+15\le 0$, or $k^2-12k+7.5\le 0$. Thus $6-\sqrt{36-7.5} \le k\le 6+\sqrt{36-7.5}$. So $1\le k\le 11$. Checking all these $k$, we get $k=3$.

Thus there are three possibilities: $k=-3,0,3$.
