H has 1 outer electron. O has 6 outer electrons ... so a triple bond forms between them. The structure of nitrogen is N≡N, showing that it has three shared pairs of electrons.
Nitrogen atoms can form three covalent bonds, so a triple bond forms between them. The structure of nitrogen is N≡N, showing that it has three shared pairs of electrons.