Hint: to produce and , write f^{-1} and f\circ g.

This is hardly surprising since equality is reflexiveAll i have so far is that

If you know that and (e.g., when all functions are bijections), then you can write , parenthesize it fully (one of the has to be done first; does it matter which?) and then apply the equalities above to gradually rewrite this into (I believe there are three steps).