$H,G$ are finite groups, and $\gcd(|H|,|G|)=1$.
I need to prove that if $\varphi:G\to H$ is homomorphism it must be the Trivial Homomorphism.
My try:
I assume that $\varphi:G\to H$ is homomorphism.
By Lagrange Theorem we know that:
$ord(a)\mid |G|,\;ord(\varphi(a))\mid |H|$ (for any $a\in G$).
We know that $ord(\varphi(a))\mid ord(a) $,
But, because $\gcd(|H|,|G|)=1\;\Rightarrow\;ord(a)=1$ (because $\gcd(ord(a),ord(\varphi(a))=1$).
This is why $\forall a\in G,\varphi(a)=e_H$, and this prove that $\varphi:G\to H$ is the Trivial Homomorphism.
$\blacksquare$
My proof is OK? Or I miss something?
Thank you!