First of all take to known acid which is monobasic and dibasic acid. Mg +H2So4 -> MgSo4 + H2 Mg + 2HCl -> MgCl2 + H2Here. , Ratio of the mole of Mg:H2 is 1:1 . it means that 1mole of Mg is equal to 1 mole of H2 .Thus, moles of Mg = mass\molar mass Mass of Mg = 12 (given) Hence , moles = 12/24 = 1/2 Thus, 1/2 moles of Mg = 1/2 moles of H2