you need a periodic table of elements.
in the periodic table, you can find certain properties of elements and and also atomic number and atomic mass.
since in the problem, we are required to calculate for molar mass of H2O, you look for H and O in the periodic table and get each atomic mass. for H, it's approximately 1 and for O it's approximately 16,,
to get mass, multiply the number of each element by atomic mass, since there are 2 H's and 1 O:
2*1 + 1*16 = 2 + 16 = 18 g/mole