Can someone help me and explain why they got what they got?

Answer:
24.32 amu
Explanation:
From the question given above, the following data were obtained:
Isotope A (Mg–24):
Mass of A = 24 amu
Abundance (A%) = 79%
Isotope B (Mg–25):
Mass of B = 25 amu
Abundance (B%) = 10%
Isotope C (Mg–26):
Mass of C = 26 amu
Abundance (C%) = 11%
Average atomic mass of Mg =?
Average atomic mass = [(Mass of A × A%)/100] + [(Mass of B × B%)/100] + [(Mass of C × C%)/100]
= [(24 × 79)/100] + [(25 × 10)/100] + [(26 × 11)/100]
= 18.96 + 2.5 + 2.86
= 24.32 amu
Thus, the average atomic mass of Mg is 24.32 amu