Congruence is an equivalence relation so transitive, so $\,x^2\equiv 79,\ 79\equiv 2\Rightarrow x^2\equiv 2,\,$ see the linked dupe.
I was wondering how in number theory we are able to determine how to quickly simplify modular congruences. So for example if I had the equation
$$x^{2} \equiv 79 \pmod 7.$$
is the same as
$$x^{2} \equiv 2 \pmod 7$$
How do I know quickly for any formula to find the smaller and equivalent congruence? I know that 77 is a factor and 77+2 is 79, but how is that the same as 2 mod 7? whats the point of having the larger number?