Hey there!
One mole of magnesium has a mass of 24.31 g.
This is 6.022 x 10²³ atoms of magnesium.
We want to convert 9.00 x 10²² atoms to moles.
For every one mole of magnesium, there are 6.022 x 10²³ atoms, so divide:
(9.00 x 10²²) ÷ (6.022 x 10²³) = 0.15 moles
Convert 0.15 moles to grams.
For every mole, there is 24.31 g.
So we multiply by 24.31. Also note that I am using the number stored in the calculator and not the rounded number I put.
0.15 × 24.31 = 3.6
The mass of 9.00 x 10²² atoms of Mg is 3.6 grams.
Hope this helps!