In NO, the oxidation number for nitrogen is N - 2 = 0
⇒ N = +2
In NO2, we have N - (2x2) =0
N - 4 =0
N =+4