In finding the derivative of g(x) = (cosx)^3
we get, g'(x) = 3(cosx)^2(-sinx)
but I don't understand how this can be simplified to
g'(x) = -3cos^2xsinx Why is is permissible to move the power of 2 to be immediately after cos instead of
after cosx?