Same kind of proof works.
So:
which by definition, is what we're looking for.
Prove that if a=bmodn and c=dmodn then a+c=b+dmodn and ac=bdmodn
My solution for the first part is:
n|(a-b) so (a-b)=nq and n|(c-d) so (c-d)=np
so (a-b) +(c-d)=nq+np
(a+c)-(b+d)=n(q+p)
So n|[(a+c)-(b+d)]
So
a+c=b+dmodn
I am not sure how to show the second part any help would be great