Prove that $\forall k$ and for any $g \in G$, the sets $A = \{a \in G : a^k = g\}$, $B = \{b \in H : b ^k = f(g)\}$ have the same number of elements.
How do we show there are the same number of elements in each of the sets?