[proofplan]
We unpack both congruence hypotheses using the definition of congruence modulo $n$ as divisibility by $n$. The additive compatibility follows by rewriting the difference of the sums as the sum of two integer multiples of $n$. The multiplicative compatibility follows by rewriting $ab-a'b'$ as a sum of two terms, each visibly divisible by $n$.
[/proofplan]
[step:Translate the congruence hypotheses into divisibility statements]
By the definition of congruence modulo $n$, the assumptions $a \equiv a' \pmod{n}$ and $b \equiv b' \pmod{n}$ mean that
\begin{align*}
n \mid (a-a')
\end{align*}
and
\begin{align*}
n \mid (b-b').
\end{align*}
Thus there exist integers $r,s \in \mathbb{Z}$ such that
\begin{align*}
a-a' = nr
\end{align*}
and
\begin{align*}
b-b' = ns.
\end{align*}
[/step]
[step:Show that the sums differ by a multiple of $n$]
Using the integers $r,s \in \mathbb{Z}$ defined above, compute
\begin{align*}
(a+b)-(a'+b') = (a-a')+(b-b').
\end{align*}
Substituting $a-a'=nr$ and $b-b'=ns$ gives
\begin{align*}
(a+b)-(a'+b') = nr+ns = n(r+s).
\end{align*}
Since $r+s \in \mathbb{Z}$, this proves $n \mid ((a+b)-(a'+b'))$. Therefore, by the definition of congruence modulo $n$,
\begin{align*}
a+b \equiv a'+b' \pmod{n}.
\end{align*}
[guided]
We want to prove a congruence between the two sums. By definition, this means we must prove that their difference is divisible by $n$. The relevant difference is
\begin{align*}
(a+b)-(a'+b').
\end{align*}
Rearranging terms in $\mathbb{Z}$ gives
\begin{align*}
(a+b)-(a'+b') = (a-a')+(b-b').
\end{align*}
From the hypotheses, we already introduced integers $r,s \in \mathbb{Z}$ satisfying
\begin{align*}
a-a' = nr
\end{align*}
and
\begin{align*}
b-b' = ns.
\end{align*}
Substituting these two equalities into the difference of sums yields
\begin{align*}
(a+b)-(a'+b') = nr+ns.
\end{align*}
Factoring out $n$ gives
\begin{align*}
(a+b)-(a'+b') = n(r+s).
\end{align*}
Because $\mathbb{Z}$ is closed under addition, $r+s \in \mathbb{Z}$. Hence $(a+b)-(a'+b')$ is an integer multiple of $n$, so
\begin{align*}
n \mid ((a+b)-(a'+b')).
\end{align*}
Applying the definition of congruence modulo $n$ again, we conclude
\begin{align*}
a+b \equiv a'+b' \pmod{n}.
\end{align*}
[/guided]
[/step]
[step:Show that the products differ by a multiple of $n$]
Again using $a-a'=nr$ and $b-b'=ns$, decompose the product difference as
\begin{align*}
ab-a'b' = ab-a'b+a'b-a'b'.
\end{align*}
Factoring the two pairs of terms gives
\begin{align*}
ab-a'b' = b(a-a')+a'(b-b').
\end{align*}
Substituting the divisibility representations gives
\begin{align*}
ab-a'b' = bnr+a'ns.
\end{align*}
Factoring out $n$ gives
\begin{align*}
ab-a'b' = n(br+a's).
\end{align*}
Since $b,r,a',s \in \mathbb{Z}$, closure of $\mathbb{Z}$ under multiplication and addition gives $br+a's \in \mathbb{Z}$. Hence $n \mid (ab-a'b')$, and therefore
\begin{align*}
ab \equiv a'b' \pmod{n}.
\end{align*}
[/step]
[step:Combine the two compatibility conclusions]
The previous two steps prove both required congruences:
\begin{align*}
a+b \equiv a'+b' \pmod{n}
\end{align*}
and
\begin{align*}
ab \equiv a'b' \pmod{n}.
\end{align*}
This completes the proof.
[/step]