Whether the center of a dihedral group is trivial or a group of order two depends upon whether the degree is odd or even.
The center of any Frobenius group is trivial.
Likewise, a non-abelian simple group has trivial center.
Of course, every abelian group is equal to its center.