Answer:
Synthesis
Step-by-step explanation:
A synthesis chemical reaction is where two simpler substances form together to create a more complex product.
The reactants can be either a single element or a compound, but the product is always a compound.
Since Mg and O2 reacted to create MgO, a compound, this represents a synthesis reaction.