Problem - 3870
Let $p$ be an odd prime divisor of number $(a^2+1)$ where $a$ is an integer. Show that $p\equiv 1\pmod{4}$.
Because $p\mid a^2+1$, therefore $a^2\equiv -1\pmod{p}$ which implies $a^4\equiv 1\pmod{p}$.
It follows that $a$ and $p$ are co-prime. Therefore, by Euler's theorem, we have $a^{\varphi(p)}\equiv 1\pmod{p}$, or $a^{p-1}\equiv 1\pmod{p}$. Thus, $4\mid (p-1)$ or $p\equiv 1\pmod{4}$.