Is the sequence of $\mathbb Z$-modules below exact? I came across the following example in my algebra textbook:
Considere the sequence of $\mathbb Z$-modules: $$0\longrightarrow \mathbb Z_2\stackrel{f}{\longrightarrow}\mathbb Z_4\stackrel{g}{\longrightarrow}\mathbb Z_2\longrightarrow 0,$$
where $f$ is the isomorphism of $\mathbb Z_2$ and the unique proper subgroup $2\mathbb Z_4$ of $\mathbb Z_4$ and $g$ is the multiplication by $2$. This is an exact short sequence.
I guess there is something strange here for if the sequence were exact $\textrm{im}(g)=\mathbb Z_2=\{\overline{0}, \overline{1}\}$ but if there were $\overline{a}\in \mathbb Z_4$ such that $2\overline{a}=\overline{1}$ in $\mathbb Z_2$ then $2|2a-1$ what certainly can't happen. 
Am I missing something?
Reference: Algèbre et Modules (I. Assem, pg. 31).

It seems to me that the second $\Bbb Z_2$ is actually $2\Bbb Z_4$, that is, it is:
$\{[0]_4,[2]_4\}$ (this is isomorphic to $\Bbb Z_2$).
It should be clear then,  that $gf = 0$, as one would expect in an exact sequence.
