Show that if $$0 \rightarrow M_1 \xrightarrow{f} M_2 \xrightarrow{g} M_3$$ is an exact sequence of $R$-modules, then for all $R$-module $$0 \rightarrow \operatorname{Hom}_R(M,M_1) \xrightarrow{f_*} \operatorname{Hom}_R(M,M_2) \xrightarrow{g_*} \operatorname{Hom}_R(M,M_3)$$is an exact sequence of $\mathbb Z$-modules ($f_*(h)=f \circ h$).
In order to show this is an exact sequence, I have to prove $Im(f_*)=Ker(g_*)$. I could show the inclusion $Im(f_*) \subset Ker(g_*)$.Let $\psi \in Im(f_*)$, then there is $h \in Hom_R(M,M_1) : f \circ h=\psi$. It is clear that $\psi \in Hom_R(M,M_2)$. Let's evaluate in $g_*$:$g_*(\psi)=g \circ \psi=g \circ f \circ h$. We want to show $\psi \in Ker(g_*)$, i.e., $g \circ \psi \equiv 0$. Let $x \in M$, then $g \circ \psi (x)= g \circ f\circ h(x)=g(f(h(x)))$. But $Im(f)=Ker(g)$, so $g(f(h(x))))=0$. From here one can conclude $\psi \in Ker(g_*)$.
I couldn't show the other inclusion, any help would be appreciated.