Demonstrate that there are no perfect squares ending with $8$

Your proof is not bad. You could make a more formal argument with modular arithmetic.

For example, $ n\equiv 0, \pm1, $ or $\pm2 \pmod 5$,

so $n^2\equiv 0, 1, $ or $-1\pmod 5$,

so $5\nmid n^2-3,$ so $10\nmid n^2-8$.


It's good but you can tweak it. Notice the palindromic symmetry: 0, 1, 4, 9, 6, 5, 6, 9, 4, 1, 0. If $n \equiv 0 \pmod{10}$, then $n^2 \equiv 0 \pmod{10}$; if $n \equiv \pm 1 \pmod{10}$, then $n^2 \equiv 1 \pmod{10}$; if $n \equiv \pm 2 \pmod{10}$, then $n^2 \equiv 4 \pmod{10}$; etc. By proving $n^2 \equiv 8 \pmod{10}$ is impossible, you've also proven it for $n^2 \equiv 2 \pmod{10}$.