TITLE: Given a group of order $p^nq^2$ for two odd primes, prove that the commutator is a p group.
QUESTION [5 upvotes]: Given a group of order $p^nq^2$ for two odd primes $p > q$, prove that the commutator is a p group.
To solve this question I need to prove that the commutator can't be of the orders $p^iq$, $p^jq^2$. I know one theorem that states that $G \diagup G'$ is abelian, but I don't think it leads anywhere. The only way left is induction on $n$, but I'm not sure how to complete the $n+1$ step.

REPLY [4 votes]: If $p>q$, then $p$ cannot divide $q^2-1$, so neither $q$ nor $q^2$ can be equal to $1$ mod $p$. Hence $G$ has a normal Sylow $p$-subgroup $P$, $|G/P|=q^2$, and $G/P$ is abelian, so $G' \le P$.