So to find the oxidation number of any element, look that element up in the periodic table and look to see what the easiest way it is for it to reach an oxidation that is "complete".
So basically just look at the columns,
Anythin in the first 3 columns will have to lose 1, 2, or 3 electrons: column 1 will have an oxidation of +1, column 2 will have +2, and column 3 will have +3.
Columns 5,6,7: 5: elements in the 5th column will have an oxidation of -3, 6 column will have -2, 7 will have -1.
Column 4: you are either + or - 4, it doesn't really matter, it's hard for them to give up 4 electrons and it's hard for them to gain 4.
Column 8: they're already complete. They are the MOST reluctant to give up anything.
H: is in the first column, which means it has 1 electron/proton. We say it has an oxidation of +1 because if it lost that 1, it would be complete. We dont' say 7 because it's easier for it to lose 1 than gain 7 to be complete (elements close to "completion" are more reluctant to give up their electrons).
Cl: it's in the 7th column so it has an oxidation of -1. We say "-1" because it needs to GAIN one NEGATIVE electron (don't mistaken that as a "+1")!