This is a question about unit conversions of atoms to grams of P. We want to understand the steps in conversions that will get us to the final unit.
When we talk about atoms or molecules, they relate to a quantity called mole. 1 mole is equal to 6.02 x 1023 atoms.
Therefore, you start with 6.91 x 1023atoms and multiply by (1 mole/6.02 x 1023atoms) to get about 1.15 moles.
After getting the number of moles, you need to know how can you relate grams and moles. You relate it through molar mass or the mass in grams of 1 mole of atoms.
In the periodic table, the molar mass of P is roughly 30.9 g/mol. Therefore, multiply 1.15 moles and 30.9 g/mol to cancel the units and get about 35.5 g.