Let $G$ be a non abelian group of order $p^3$, with $p$ prime.
I'm proving that $Z(G)$ (its center) is of order $p$. I already know how to do it by saying that its order can't be $p^3$, nor 1, and if it's $p^2$ then $G/Z(G)$ is cyclic then G is abelian, Abs!
But I've been reading another way of proving it and the author supposes that $|Z(G)|=p^2$. Then, she says: "$\exists\ x$ outside the center of $G$, of order $p$." Could someone give me a hint? Thanks!
Take an element $a$ outside the center $Z(G)$. This is possible as the group is supposed to be non abelian. The order of $a$ divides $p^3$. If the order of $a$ is $p$ you're done. If it is $p^2$ then $a^p$ is of order $p$.