Solution (source code)

= Solution

Suppose $G/Z(G)$ is generated by $gZ(G)$. Every element of $G$ can then be written $g^az$ with $z\in Z(G)$. Hence
$$
(g^az_1)(g^bz_2)=g^{a+b}z_1z_2
=(g^bz_2)(g^az_1).
$$
Thus the <cyclic quotient by the center> condition forces $G$ to be abelian.

If $|H/Z(H)|=7$, the quotient has prime order and is therefore cyclic. The result just proved would make $H$ abelian, so $Z(H)=H$ and the quotient would have order one, a contradiction. Therefore
$$
\boxed{\text{no such group }H\text{ exists}.}
$$