I understand this proposition has been proven many times across this forum, but my first attempt at a proof led me to a strategy that I haven't seen anywhere. I'm curious if it is a valid approach.
Let $n = k^2, k \in \mathbb{Z}$. Assume for contradiction that $n+2 = j^2, j \in \mathbb{Z}$.
$n=k^2 \Rightarrow k^2 +2 = j^2 \Rightarrow \sqrt{k^2 + 2} = j$
$j \notin \mathbb{Z}$, which contradicts assumption. Therefore, $n+2$ is not equal to a perfect square.
Did I go wrong anywhere here?
As others commented, how do you know with $k\in\mathbb Z$ that $j=\sqrt{k^2+2}\not\in\mathbb Z$?
Here's a proof:
We may assume without loss of generality that $k\ge0$.
For $k\ge1$, $(k+1)^2=k^2+2k+1>k^2+2=j^2$, so $k<j<k+1$, so $j\not\in\mathbb Z$.
For $k=0, j=\sqrt{k^2+2}$ is not an integer either.