\(\displaystyle a^2\equiv 1 \ \mbox{(mod m)}\)

\(\displaystyle (m-a)^2\equiv 1 \ \mbox{(mod m)}\rightarrow m^2-2am+a^2\equiv 1 \ \mbox{(mod m)}\rightarrow m^2-2am+1\equiv 1 \ \mbox{(mod m)}\)

\(\displaystyle \rightarrow m-2a\equiv 0 \ \mbox{(mod 1)}\)

Not sure if this is going anywhere.