A mole is a measure of amount, like a dozen meaning twelve. When they ask for the number of moles in 20g of Hydrogen gas, you are supposed to convert the 20g of hydrogen to the number of molecules present (your teacher or the problem should provide it, otherwise a simple Google search would do) then convert that number to be represented by moles (which is (6.022 x 10^23 particles). In the second part, you need to double that answer, since it's just H2.