Consider $m\in\mathbb{Z}, n\in\mathbb{N}$. Then there exist unique elements $q\in\mathbb{Z}, r\in\mathbb{N}$ with $0\leq r<n$ and $m=qn+r$. We write $r:=m\% n$. Show by explicit calculation that $$ \varphi\colon\mathbb{Z}\to\mathbb{Z}_n, m\mapsto m\% n $$ is a surjective ringhomomophism.
I am a little bit confused.
So here I have two rings , namely $(\mathbb{Z},+,\cdot)$ with the usual addition and multiplication and $(\mathbb{Z}_n,\oplus,\odot)$, whereat last two operations are (as far as I know) defined by $$ (x+n\mathbb{Z}) \oplus (y+n\mathbb{Z}):=(x+y)+n\mathbb{Z},~~~~~(x+n\mathbb{Z})\odot (y+n\mathbb{Z}):=(x\cdot y)+n\mathbb{Z}. $$
So if I understand the function $\varphi$ right, it takes a $x\in\mathbb{Z}$ and then maps this to the rest of the division $x : n$, which lies in one of the residue classes within $\mathbb{Z}_m$, i.e. is a representative of one residue class in $\mathbb{Z}_n$.
What I have to show is that $$ \varphi(x+y)=\varphi(x)\oplus\varphi(y),~~~ \varphi(x\cdot y)=\varphi(x)\odot\varphi(y)~~~\forall~x,y\in\mathbb{Z}. $$
But I do not know how the operations $\oplus$ and $\odot$ are definied for representatives of residues classes.
Additionally, I do not know, what is meant with shwowing this by explicit calculation.
Edit: Here is my proof:
I.Ring homomorphism:
$$ \varphi(x+y)\\ =(x+y)\%n+n\mathbb{Z}\\ =(x\%n + y\% n)\% n + n\mathbb{Z}\\ =x\%n + n\mathbb{Z}\oplus y\%n+n\mathbb{Z}\\ =\varphi(x)\oplus\varphi(y) $$ $$ \varphi(x\cdot y)\\ =(x\cdot y)\% n+n\mathbb{Z}\\ =(x\%\cdot y\%n)\%n+n\mathbb{Z}\\ =x\%n+n\mathbb{Z}\odot y\%n+n\mathbb{Z}\\ =\varphi(x)\odot\varphi(y)\\ $$
II. Surjectivity:
Consider any $z:=x\%n+n\mathbb{Z}\in\mathbb{Z}_n$ then $z=\varphi(x)$.
Pls write me in a comment if the proof is right and complete now, thanks.