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

Proposition. Let $G$ be a group of order $p^n$, with $p$ prime and $n \ge 1$. Then $Z(G) \ne \{e\}$.
Proof. By contrapositive, suppose $Z(G)=\{e\}$; so, all the centralizers are proper subgroups of $G$ and have then order of the form $p^\alpha$ with $\alpha < n$. Therefore, the Class Equation reads:
$$p^n=1+\sum_i p^{\beta_i}$$
where $\beta_i \ge 1, \forall i$. But then, $p \mid p^n-\sum_i p^{\beta_i}=1$: contradiction.  $\quad \Box$
Corollary. Let $G$ be a group of order $p^2$, with $p$ prime. Then $G$ is abelian.
Proof. By contrapositive, suppose $G$ non abelian; then, $\exists \tilde a \in C_G(\tilde a) \setminus Z(G)$, so that $Z(G) \lneq C_G(\tilde a) \le G$. By the Proposition, $|Z(G)|=p$ and $|C_G(\tilde a)|=p^2$, whence $C_G(\tilde a)=G$ and $\tilde a \in Z(G)$: contradiction. $\quad \Box$
