In order to find the number of moles in a sample we are tasked with first finding the number of moles in that sample. This is because the moles in a substance indicates the amount of the substance that contains the same number of particles as 12 g of the Carbon-12 isotope [or equivalent to 6.02 × 10²³ (which is used as a standard in the world of moles).
Now,
If moles = mass ÷ molar mass
then mol of aluminum = 100 g ÷ 27g/mol
= 3.704 mol
Now that you have calculated the moles then you can do a simple ratio and multiplication at arrive at the number of atoms that would be present in the 100 g of aluminum.
if 1 mol of aluminum contains 6.02 × 10²³ atoms
then let 3.704 mol of aluminum contain x
∴ x = 3.704 mol × (6.02 × 10²³)
= 2.23 × 10²⁴
∴ 100 g of Al would contain ~ 2.23 × 10²⁴ atoms