Here's why:
* Covalent Bonds: In covalent bonds, atoms share electrons to achieve a stable electron configuration.
* Oxygen: Each oxygen atom has six valence electrons (electrons in the outermost shell). By sharing two electrons with another oxygen atom, both oxygen atoms achieve a stable octet (eight electrons) in their outermost shell. This forms a double bond between the oxygen atoms.
* Nitrogen: Each nitrogen atom has five valence electrons. By sharing three electrons with another nitrogen atom, they both achieve a stable octet. This forms a triple bond between the nitrogen atoms.
So, the strong covalent bonds in both oxygen and nitrogen gas are what hold the molecules together.