Is there any reference that contains this proof:
Show that if $M$ is projective then $\operatorname{Hom}_R(M,.)$ is an exact functor.
Or any help in the proof will be appreciated.
We defined projective module as follows:
An $R$-module $P$ is projective if, whenever $A,B$ are $R$-modules, $f \in \operatorname{Hom}_R(P,B),$ and $g \in \operatorname{Hom}_R(A,B),$ is surjective, there exists $\tilde{f} \in \operatorname{Hom}(P,A)$ such that $f = g \tilde{f}.$
And I proved that the $\operatorname{Hom}_R(M, -)$ functor is a left exact functor. Also, I have proved if $P$ is free then $P$ is projective.
Any help will be appreciated.
EDIT:
I already solved this problem:
$(a)$ Let $P$ be an $R$-module. Show that the following three conditions are equivalent.\ 1.$P$ is projective.\ 2. Any surjective homomorphism $g: A \rightarrow P$ of $R$-modules has a section.\ 3. $P$ is a direct summand of a free module, i.e.,there is a free $R$-module $F$ and submodule $Q$ such that $F = P \oplus_R Q.$\
$(b)$ Part $(a)$ shows that, if $P$ is free, then $P$ is projective. Give an example of a finitely generated projective module which is not free.\
Projectivity is basically defined to be exactly right exactness of $\hom_R(M,-)$; suppose we have a short exact sequence
$$0\to A\to B\overset g\to C\to 0.$$
Now you want to know that
$$0\to\hom_R(M,A)\to\hom_R(M,B)\to\hom_R(M,C)\to0$$
is right exact (you've already checked left exactness). So we really just need surjectivity of $\hom_R(M,B)\to\hom_R(M,C)$. If you have an element $f\in\hom_R(M,C)$, then by projectivity of $M$ you know there exists some $\tilde f\in\hom_R(M,B)$ such that $f=g\tilde f$. Unraveling the definitions check this is really just saying that $\tilde f\mapsto f$ under $\hom_R(M,B)\to\hom_R(M,C)$.