The mass of an element is expressed in amu (atomic mass units). If you look at the Periodic Table of Elements for Carbon (C) you will see that the amu of C = 12.
1 mole of C atoms = 6.02 x 10 to the 23rd (Avogadro's number) of atoms.
1 mole of C atoms (Avogadro's number of C atoms) weighs 12 grams (atomic mass expressed in grams).
Hydrogen has an amu of 1. This is for hydrogen atoms - remember that hydrogen is a diatomic element and that hydrogen in its elemental form (not combined) has a mass of 2 amu (for hydrogen molecules).
Therefore, 1 mole of H atoms (Avogadro's number) weighs one gram.
To solve for amu, if you have grams, divide by Avogadro's number.