Old samples of magnesium oxide become contaminated with magnesium carbonate. Suggest how this contamination takes place
Carbonate contamination in oxides compounds often happens after a certain time and air exposure because of the $\ce {CO2}$ in the air.  

For your magnesium oxide it follows the reaction  

$\ce {MgO + CO2 -&gt; MgCO3}$  

with $\ce {MgCO3}$ being the magnesium carbonate.

A solution to prevent this kind of polution is to keep the oxide in a dessicator or to treat them in a furnace at a temperature around to $500 °C$ wich is the decomposition temperature of most of the carbonate compounds.