First, we calculate the relative abundance of magnesium-26 by subtracting the given percentages from 100%,
100 - 78.9 - 10 = 11.1%
Next, we the method for the calculation of average atomic mass is that we multiply the mass of each isotope by its relative abundance and add the product for each of the isotopes. Then, we divide by 100 to remove the percentages and we get the average atomic mass. This is:
Ar = (23.985 * 78.9 + 24.9858 * 10 + 25.9826 * 11.1) / 100
Ar = 24.3608 amu
The average atomic mass of magnesium is 24.3068 amu