Problem

Source: Centroamerican 2020, problem 1

Tags: number theory, Digits



A four-digit positive integer is called virtual if it has the form $\overline{abab}$, where $a$ and $b$ are digits and $a \neq 0$. For example 2020, 2121 and 2222 are virtual numbers, while 2002 and 0202 are not. Find all virtual numbers of the form $n^2+1$, for some positive integer $n$.