H - Oxidation number : 1
O - Oxidation number : -2
N - Oxidation number : -3
In A and B, as Nitrogen forms a covalent bond with Hydrogen (Ammonia) and Oxygen (Nitrate, Nitrogen Oxide), the oxidation number will remain as -3.
In C, we know that the valency of Nitrogen molecule is zero, and we know that when Nitrogen forms a covalent bond with Hydrogen (Ammonia), the oxidation number will be -3, since its oxidation number has decreased, we can tell that a reduction has taken place.
In D, we know that the valency of Nitrogen molecule is zero, and we know that when Nitrogen forms a covalent bond with Hydrogen (Ammonia), the oxidation number will be -3, since its oxidation number has increased, we can tell that a oxidation has taken place.