A problem asked me to show that a group, $G$, of order $1225= 5^{2}\times 7^{2}$ is abelian. I did this by using Sylow's Theorem to show that we have two normal subgroups: one of order $49$ and the other of order $25$. Since the intersection of these subgroups must be $1$, it follows that $G$ is a direct product of these two subgroups. But subgroups of order $p^{2}$ are abelian, where $p$ is a prime. Thus $G$ is abelian.
The question I have upon completing this proof is that it seems to imply that $G$ is isomorphic to $Z_{25} \times Z_{49}$. But this isn't always that case since $Z_{35} \times Z_{35}$ is also a group of order $1225$. Where is my argument failing?