Example 12 Find all $a \in \mathbf{Z}_{+}$ such that for any $n \in \mathbf{Z}_{+}, n(n+a)$ is not a perfect square. ${ }^{[2]}$
(32nd Argentine Mathematical Olympiad)
Solve: Since
$$
\begin{array}{l}
n^{2}<n(n+1)<n(n+2) \\
<(n+1)^{2}<n(n+4) \\
<(n+2)^{2},
\end{array}
$$

Therefore, when $a=1,2,4$, for any $n \in \mathbf{Z}_{+}, n(n+a)$ is not a perfect square.

When $a$ is an odd number not less than 3, take $n=\left(\frac{a-1}{2}\right)^{2}$, then $n(n+a)=\left(\frac{(a-1)(a+1)}{4}\right)^{2}$, which does not meet the requirement;

When $a$ is an even number not less than 3, $a=2^{k}(k \geqslant 3)$ or $a=2^{k} b(k \geqslant 1, b$ is an odd number not less than 3 $)$.
If $a=2^{k}(k \geqslant 3)$, take $n=2^{k-3}$, then
$$
n(n+a)=\left(3 \times 2^{k-3}\right)^{2} \text {, }
$$

which does not meet the requirement.
If $a=2^{k} b(k \geqslant 1, b$ is an odd number not less than 3 $)$, take $n=2^{k}\left(\frac{b-1}{2}\right)^{2}$, then
$$
n(n+a)=\left(2^{k} \frac{(b-1)(b+1)}{4}\right)^{2},
$$

which does not meet the requirement.
In summary, only when $a=1,2,4$, for any $n \in \mathbf{Z}_{+}, n(n+a)$ is not a perfect square.

[Commentary] The solution approach is to first find the $a$ that satisfies the problem condition based on adjacent (or alternate) perfect squares, and then prove that other cases do not meet the requirement by solving the indeterminate equation
$$
n(n+a)=(n+m)^{2} \Leftrightarrow a=2 m+\frac{m^{2}}{n}
$$