# Show that $G\cong\ker f\times f[G]$ ($G$ finite and abelian)

Let $G$ be a finite group, and consider $f\colon G\to G\colon g\mapsto g^2$.

In previous exercises, I showed the following:

1) $f$ is a groups morphism iff $G$ is abelian

2) Assume $G$ is abelian. Then $f$ is an isomorphism iff the order of $G$ is odd.

3) Assume $G$ is abelian and has no elements of order 4. Then $f_{\vert f[G]}$ is an isomorphism.

The last thing I’m asked to show is the following: assume $G$ is abelian and has no elements of order 4. Show that: $G\cong\ker f\times f[G]$.

I'm not sure how to go about this. I know the kernel exists of elements of order $\leq 2$. And $f[G]$ kind of 'loses' all elements of order 2 of $G$, because those are mapped to $\{e\}$ by $f[G]$. But how to make this rigorous?

Let's construct a homomorphism $\varphi : \ker f \times f[G] \to G$.
We would want it to take $(h,f(g))$ to $f(g)h$.
To show that it is injective, let $f(g)h = f(g')h'$, i.e. $f(g'g^{-1}) = h'h^{-1}$, i.e. $(g'g^{-1})^2 = h'h^{-1}$. But $h'h^{-1} \in \ker f$, so it has order $1$ or $2$. If it has order $2$, then $g'g^{-1}$ would have order $4$, contradiction. So $h'h^{-1}$ has order $1$, i.e. $h'h^{-1} = e$, i.e. $h' = h$ and $f(g) = f(g')$.
To show that it is bijective, note that $| \ker f \times f[G] | = |G|$ by first isomorphism theorem, so it is enough to show that it is injective.