Let $(G, \cdot, e)$ be a group. For homomorphisms $\theta: \mathbb{Z} \rightarrow G$, $\psi: \mathbb{Z} \rightarrow G$, define the componentwise product as $\theta \cdot \psi: \mathbb{Z} \rightarrow G; n \mapsto \theta(n)\psi(n)$
Show that $G$ is abelian iff the following condition is satisfied:
For all homomorphisms $\theta: \mathbb{Z} \rightarrow G$, $\psi: \mathbb{Z} \rightarrow G$, the componentwise product $\theta \cdot \psi$ is also a homomorphism.
For the ($\Rightarrow$) direction, I have, for any homomorphisms $\theta, \psi$ and $n, m \in \mathbb{Z}$, \begin{align*} \theta \cdot \psi (nm) & = \theta(nm)\psi(nm) & \\ & = \theta(n)\theta(m)\psi(n)\psi(m) & \text{since $\theta, \psi$ are homomorphisms} \\ & = \theta(n)\psi(n)\theta(m)\psi(m) & \text{since $G$ is abelian}\\ & = (\theta \cdot \psi(n)) \cdot (\theta \cdot \psi (m)). & \end{align*}
For the ($\Leftarrow$) direction, I don't see why this is true.
I want to show that for any two elements $a,b \in G$, we have $ab = ba$. If I know that $a$ and $b$ are in the image of some homomorphism, then the result follows because we can say that if $a = \theta(n)$ and $b = \psi(m)$ for some $n, m \in \mathbb{Z}$, then \begin{equation*} \theta \cdot \psi (nm) = \theta(n)\theta(m)\psi(n)\psi(m) = \theta(n)\psi(n)\theta(m)\psi(m), \end{equation*} so $ab = \theta(n)\psi(m) = \psi(m)\theta(n) = ba$.
However, it is not clear to me why any element of $G$ is the in the image of one of our homomorphisms because we don't have surjective homomorphisms.
Can I claim that since we're considering all homomorphisms from $\mathbb{Z} \rightarrow G$, given an element in $G$, there exists a homomorphism that maps some integer to that element?
Hint: For any two elements $g,h$, there's $\phi,\theta: \Bbb Z\to G$ such that $$\phi(1)=g,\theta(1)=h.$$
What does it mean that $\phi\cdot\theta(2)=\phi(2)\cdot\theta(2)$?