Both the reactions are in accordance with the principle of stoichiometry.
In the first reaction,
Both the reactants are completely consumed to form product according to reaction stoichiometry. 1 mol hydrogen + 1 mol chlorine → 2 mol hydrogen chloride.
In the second reaction,
Chlorine is the limiting reagent and it is completely consumed to form hydrogen chloride.
Excess hydrogen remains unreacted at the end of the reaction.
This reaction also follows principle of stoichiometry.
2 mol hydrogen + 1 mol chlorine → 2 mol hydrogen chloride + 1 mol hydrogen