Answer:
Mg has two valence electrons
Explanation:
Na has only one valence electron, so it readily donates that electron to other atoms to achieve an octet.
Mg must lose two valence electrons to get an octet. It takes extra energy to remove the second electron. In addition, the two electrons are in a filled s subshell, which has added stability.