Prove if $7\mid a^2+b^2 \longrightarrow 7\mid a$ and $7\mid b$
What I did:
I found the possible remainders for $a^2$ are $0, 1, 2$ and $4$.
I think I should say $r_7(a^2)+r_7(b^2)$ can't equal any multiple of $7$ unless both of them are $0$?
And if both of them are $0$, that implies $r_7(a)=0$ and $r_7(b)=0$
Am I correct? How can I explain this in mathy terms?