Find all possible integers $n$ such that $\sqrt{n + 2} + \sqrt{n + \sqrt{n + 2}}$ is an integer. 
Find all possible integers $n$ such that $m = \sqrt{n + 2} + \sqrt{n + \sqrt{n + 2}}$ is an integer.

Guess what? This problem is adapted from a recent competition. There have been a solution below for you to check out. I am aware of the fact that there are other solutions that are more practical and suitable in test setting.

We have that $$m = \sqrt{n + 2} + \sqrt{n + \sqrt{n + 2}} \ (m \in \mathbb N)$$
$$\iff m - \sqrt{n + 2} = \sqrt{n + \sqrt{n + 2}} \iff (m - \sqrt{n + 2})^2 = n + \sqrt{n + 2}$$
$$\iff m^2 - (2m - \sqrt{n + 2})\sqrt{n + 2} = (\sqrt{n + 2} + 1)\sqrt{n + 2} - 2$$
$$\iff m^2 + 2 = (2m + 1)\sqrt{n + 2} \iff \sqrt{n + 2} = \frac{m^2 + 2}{2m + 1}$$
As an addition, $\dfrac{m^2 + 2}{2m + 1} \in \mathbb Q^+, \forall m \in \mathbb N \implies \sqrt{n + 2} \in \mathbb Q^+$
$\implies \sqrt{n + 2} \in \mathbb N \implies \dfrac{m^2 + 2}{2m + 1} \in \mathbb N \iff \dfrac{4(m^2 + 2) - (2m + 1)(2m - 1)}{2m + 1} \in \mathbb N$
$\iff \dfrac{9}{2m + 1} \in \mathbb N \iff 2m + 1\mid 9 \iff 2m + 1 \in \{1, 3, 9\} \iff m \in \{0, 1, 4\}$
We can set up a table for different value of $m$ and $\sqrt{n + 2}$.
$$\begin{matrix} m&& 0&& 1&& 4\\ \sqrt{n + 2} = \dfrac{m^2 + 2}{2m + 1}&& 2&& 1&& 2 \end{matrix}$$
$\iff n \in \{-1, 2\}$.
Plugging $n \in \{-1, 2\}$ in $m = \sqrt{n + 2} + \sqrt{n + \sqrt{n + 2}}$, we have that $(m,n) = (1, -1)$ and $(m, n) = (4, 2)$ is the correct answer.
