What happens inside an electric generator?

A.
electrical energy is converted to magnetic energy

B.
chemical energy is changed to magnetic energy

C.
mechanical energy is changed to electrical energy

D.
magnetic energy is converted to electrical energy