Question 147
Let $n \geqslant 2$ be an integer. The $n^{2}$ integers $1,2, \ldots, n^{2}$ are placed in the $n^{2}$ cells of an $n \times n$ chessboard as follows: the first row contains the numbers $1,2, \ldots, n$ (from left to right), the second row contains the numbers $n+1, n+2, \ldots, 2 n$, and so on. At each step, one may choose two cells sharing a common side and add the same integer to, or subtract the same integer from, the two numbers in these two cells.
Find all values of $n$ for which it is possible to obtain the configuration consisting only of 0s, and in that case find the minimum number of steps needed to achieve it.
Find all values of $n$ for which it is possible to obtain the configuration consisting only of 0s, and in that case find the minimum number of steps needed to achieve it.