Mg0 + O20 MgIIO2-I

This is an oxidation-reduction (redox) reaction:

Mg0 - 2 e- MgII (oxidation)

2 O0 + 2 e- 2 O-I (reduction)

Change the oxidation states