Introduction to group theory/Socks and shoes proof

Let ${\displaystyle G}$ be a group and let ${\displaystyle a,b\in G}$. Then ${\displaystyle (a*b)*(b^{-1}*a^{-1})=a*(b*b^{-1})*a^{-1}=a*e*a^{-1}=a*a^{-1}=e}$. Also ${\displaystyle (b^{-1}*a^{-1})*(a*b)=b^{-1}*(a^{-1}*a)*b=b^{-1}*e*b=b^{-1}*b=e}$. Thus ${\displaystyle (ab)^{-1}=b^{-1}a^{-1}}$ by definition of inverse.