Another way of proving option C
For Groups we know cancellation property holds, i.e.
a.b=a.c ⇒ b=c (why this is true ?, because we have inverse element for each group. see this)
Having known this,
(goh)2=(goh)o(goh) = gohogoh (im removing bracket because groups are associative ).
Now LHS becomes gohogoh. and RHS is g2oh2. We want to proof gohogoh = g2oh2.
gohogoh = g2oh2
⇒g̶ohogoh =g2̶oh2 (cancel leftmost g from each sides, then it becomes hogoh = goh2)
Similarly, cancel rightmost h from both sides. then it becomes hog = goh.
which is true for abelian groups, since abelian groups are commutative.