Question about kernel of a homomorphic function relating to the characteristic of a ring Let $R$ be a ring with identity.  If there is a smallest positive integer $n$ such that $n1_R=0_R$, then $R$ is said to have characteristic $n$.
Also the kernel of a function is defined for a function $f:R\rightarrow S$ as $K=\{r\in R\mid f(r)=0_S\}$ 
1a Let $R$ be a ring with identity.  Show that the map $f:\mathbb{Z}\rightarrow R$ given by $f(k)=k1_R$ is a homomorphism.
1b) Show that the kernel of $f$ is the ideal $(n)$, where $n$ is the characteristic of $R$
I have done 1a.  My questions are for 1b. 
I know that if for all $n\in \mathbb{Z}$ where $n>0$, $n1_R\neq 0$, then the characteristic of $R$ is zero, since the only way that $n1_R= 0$ is when $n=0$.  Also, in the case where if there exist a smallest $n$ such that $n1_R=0$, then the ring $R$ is said to have characteristic $n$. If I let kernel of $f(n)=n1_R$, to be defined as $K=\{n\in \mathbb{Z}\mid f(n)=nl_R=0\}$.  $R$ having characteristic zero would be $K\neq\{0_{\mathbb{Z}}\}$ and $R$ having characteristic $n$ would be $K=\{0_{\mathbb{Z}}\}$.  I am not sure for which cases of the kernel, whether it is $K\neq\{0_{\mathbb{Z}}\}$, or $K=\{0_{\mathbb{Z}}\}$ that would allow me to show that it is equal to the ideal $(n)$.  I need to show $K\subset (n)$ and $(n) \subset K$.  Lastly, if I know what the kernel is for either cases, I can use the first isomorphism theorem for rings to show in the former, it is isomorphic to ${\mathbb{Z}}$ while in the latter case is isomorphic to ${\mathbb{Z}/n\mathbb{Z}}$. I am not sure if that will resolve the question.  Thank you in advance.

You're incorrect about  $K $.  What happens is $K=\{0\} $ precisely when  $\rm {char}R=0$.  Otherwise,  if $\rm {char}R=n $ we get $K=(n) $.
The proof is straight forward.   Suppose  $f (k)=0$.  Then $k\cdot1_R=0$.  So $n\mid k $ (technically you should probably use the Euclidean algorithm here), or $k\in (n) $.  Conversely,  say $k\in (n) $.   We have  $k=mn $, then $f (k)=mn\cdot1_R=m (n\cdot1_R)=m (0)=0 $.
