
Modular
I have two questions involving mod m that I am struggling with and I was hoping someone could give me some tips on how to start and or complete them
1. if a = b(mod m) and a = b(mod n), prove a = b(mod mn), I know that m and n are relatively prime. So the greatest common divisor of m and n is 1
2. If x^2 = a^2 (mod p), prove x= a(mod p) or x = a (mod p). Where p is a prime..

For $\displaystyle 1)$, use the definition of congruence, and the fact that if $\displaystyle (m,n)=1$, $\displaystyle m\mid A$ and $\displaystyle n \mid A$ then $\displaystyle mn \mid A$.
For $\displaystyle 2)$, notice that $\displaystyle x^2a^2 \equiv 0 \mod p \Rightarrow (xa)(xb) \equiv 0 \mod p$. Then use the fact that when $\displaystyle yz \equiv 0 \mod p$ then either $\displaystyle y\equiv 0$ or $\displaystyle z \equiv 0 \mod p$.