(a) Oxidized atom — Mg
Equation of oxidation — Mg → Mg2+ + 2e-
Reduced atom — F
Equation of reduction — F + e- → F-
Oxidizing agent — F
Reducing agent — Mg
(b) Oxidized atom — Na
Equation of oxidation — Na → Na + 1e-
Reduced atom — Cl
Equation of reduction — Cl + 1e- → Cl-
Oxidizing agent — Na
Reducing agent — Cl