To convert a given mass to the number of moles, we make use of the molar mass conversion factor. In the calculation, the mass of HCl will be divided by the molar mass. In this manner, the unit of moles will be expressed in the numerator while the unit of grams will be expressed in the denominator. With this calculation, the unit of grams will be canceled out, leaving only with the unit of moles.