About an order of a p-group I'm trying to show that if G is a Group, then $|G| = p^2 \Rightarrow G$ is abelian.
The path I'm taking relies on supposing that $|Z(G)| = p$ and forming the quotient group $\overline{G} = G/Z(G)$. 
Then we got $\overline{G}$ as a cyclic group, because it has order p. $\overline{G}=<a.Z(G)>, \ a \in G$.
By that way, on the texts I saw, it's said that I can assume every element in $G$ is in the form of $(a^n)b$, $a \in G$ and $b \in Z(G)$. Why can I assume this?
Thank you

It's well known that the center of a $p$-group is nontrivial.  This can be seen by looking at the class equation.
The rest goes through without a hitch.
