Show that a Z-module A is flat if and only if it is torsion-free? I found a question in my textbook which really confuses me! 

Show that a $\mathbb Z$-module $A$ is flat if and only if it is torsion-free?  

Over here, "torsion-free" is defined as follows: An abelian group $A$ is torsion-free if and only if any nonzero element of $A$ has infinite order! 
Can someone tell me how to prove this question?
 A: Theorem: Let $M$ be an $R$-module.  The following are equivalent:
(i): $M$ is flat over $R$.
(ii): $\textrm{Hom}_{R}(-, \textrm{Hom}_{\mathbb{Z}}(M,\mathbb{Q}/\mathbb{Z}))$ is an injective $R$-module.
(iii): For any ideal $I$ of $R$, the natural map $I \otimes_R M \rightarrow IM$ is an isomorphism.
Lemma:Let $\phi: A \rightarrow B$ a homomorphism of abelian groups.  Suppose the natural map $$\phi^{\ast}: Hom(B, \mathbb{Q}/\mathbb{Z}) \rightarrow Hom(A, \mathbb{Q}/\mathbb{Z})$$ is surjective.  Then $\phi$ is injective.
Proof: We begin with some reductions.  First, $\phi$ is injective if and only if its restriction to any finitely generated subgroup of $A$ is injective.  And, $\mathbb{Q}/\mathbb{Z}$ being an injective abelian group, it is easy to see that our hypothesis is inherited by any subgroup of $A$.  So without loss of generality, we may suppose that $A$ is finitely generated.  
Also, if we split $\phi$ up into a surjective homomorphism followed by an injective homomorphism, as $A \xrightarrow{\phi'} Image \phi \xrightarrow{i} B$, where $i$ is the inclusion map and $\phi'$ is the map $\phi$ with its codomain replaced by $Image \phi$, we can split the map $\phi^{\ast}: Hom(B, \mathbb{Q}/\mathbb{Z}) \rightarrow Hom(A, \mathbb{Q}/\mathbb{Z})$ up into a composition $$ Hom(B, \mathbb{Q}/\mathbb{Z}) \xrightarrow{i^{\ast}} Hom(Image \phi, \mathbb{Q}/\mathbb{Z}) \xrightarrow{\phi^{'\ast}} Hom(A, \mathbb{Q}/\mathbb{Z}) $$ By our hypothesis, the composition $\phi^{'\ast} \circ i^{\ast}$ is surjective, so $\phi^{'\ast}$ must also be surjective.  So without loss of generality, we may suppose that $\phi$ is surjective.
Let $K$ be the kernel of $\phi$.  From the exact sequence $0 \xrightarrow{} K \xrightarrow{i} A \xrightarrow{\phi} B \rightarrow 0$, we apply the exact functor $\mathcal F := Hom(-, \mathbb{Q}/\mathbb{Z})$ to get another exact sequence $$ 0 \rightarrow \mathcal F(B) \xrightarrow{\phi^{\ast}} \mathcal F(A) \xrightarrow{i^{\ast}} \mathcal F(K) \rightarrow 0 $$
 Now $\phi^{\ast}$ is surjective by hypothesis.  On account of the fact that $i^{\ast}$ is surjective with kernel $Image \phi^{\ast} = \mathcal F(A)$, we can conclude that $\mathcal F(K)$ is zero.
Now $K$ is a subgroup of $A$, and $A$ is finitely generated, so $K$ is also finitely generated.  And we want to show that $K = 0$, i.e. $\phi$ is injective.  So to finish the proof, it suffices to prove the following: if $G$ is a finitely generated abelian group, and $Hom(G, \mathbb{Q}/\mathbb{Z})$ only consists of the zero map, then $G = 0$.  
If $G \neq 0$, we may write $G$ as a finite direct sum of $\mathbb{Z}$s and $\mathbb{Z}/n\mathbb{Z}$s for various $n$.  Giving a trivial homomorphism of $G$ into $\mathbb{Q}/\mathbb{Z}$ is equivalent to giving nontrivial homomorphisms  of $\mathbb{Z}$ and $\mathbb{Z}/n\mathbb{Z}$ into $\mathbb{Q}/\mathbb{Z}$ (one can take  a finite direct sum out of the first variable in $Hom$).  And these certainly exist.  There is a nonzero homomorphism of $\mathbb{Z}/n\mathbb{Z}$ into $\mathbb{Q}/\mathbb{Z}$ by the formula $\overline{k} \mapsto \frac{k}{n} + \mathbb{Z}$.  As for $\mathbb{Z}$, we obtain a homomorphism by composing with the projection onto $\mathbb{Z}/n\mathbb{Z}$.
Proof of theorem: I realize I really don't want to type all this out.  But the lemma above is really the hardest part of the proof.  (i) $\Rightarrow$ (iii) is easy, (iii) $\Rightarrow$ (ii) you can use Baer's criterion and the Hom-Tensor adjointness formula, and (ii) $\Rightarrow$ (i) you can use the Hom-Tensor adjointness and the Lemma.
A: I am not sure if you are aware of or are permitted to use this result, but if you are allowed, the proof is very short:

Let $R$ be a commutative ring with identity, and let $A$ be a module over $R$.  Then $A$ is flat over $R$ if and only if for any ideal $I$ of $R$, the natural map $I \otimes_R A \rightarrow R \otimes_R A \cong A$, is injective.

In other words, instead of showing $- \otimes_{\mathbb{Z}} A$ preserves all exact sequences, it suffices to show that it preserves exact sequences of the form $0 \rightarrow I \rightarrow \mathbb{Z}$, where $I$ is an ideal of $\mathbb{Z}$.  So for any ideal $I$ of $\mathbb{Z}$, let's show that the natural map $I \otimes_{\mathbb{Z}} A \rightarrow A, x \otimes a \mapsto xa$ is injective.
We have $I =  n\mathbb{Z}$ for some integer $n$.  The elements of $I \otimes_{\mathbb{Z}}A$ are all elementary tensors of the form $n \otimes a : a \in A$.  For example, the sum $k_1n \otimes a_1 + k_2 n \otimes a_2$ is equal to $n \otimes (k_1a_1 + k_2a_2)$.
Now suppose $n \otimes a$ maps to zero in $A$.  So $na = 0$.  But $A$ is torsion-free, so this implies $a = 0$. Hence $n \otimes a = 0$.
I should add that the same exact argument will work if you replace $\mathbb{Z}$ with any principal ideal domain $R$.  Even more generally, flat is equivalent to torsion-free when $R$ is any ring whose localization at every maximal ideal is a principal ideal domain.  For example, this holds when $R$ is a Dedekind domain.  This is because flatness is a local property.
