I am trying to solve the following problem.
Find perfect square which last 4 digit is 9009
The solution in the textbook starts as follows.
Let $x$ be the one we want to obtain. Then $x^2 = 10000y + 9009$. Then $x=10a \pm 3$.
I am confused with the last part. why $x=10a\pm 3$?
Let $x=10a\pm b,0\le b\le5$
$\implies b^2\equiv0,1,4,9,5\pmod{10}$
$x^2=10(10a^2\pm2ab)+b^2\equiv b^2\pmod{10}$