If $G$ has no proper-nontrivial subgroups then $G$ is cyclical with order $p$, prime.
I already proved that $G$ is cyclical.
If the order of $G=\langle g\rangle $ is $ab,$ with $1<a<ab$, then $g^{ab}=1,$ then $(g^b)^a=1$ then $\langle g^b\rangle $ has order $a<ab$, and this subgroup is proper (contradiction)