A binary compound is a compound formed from two different elements. There may or may not be more than one of each element. A diatomic compound (or diatomic molecule) contains two atoms, which may or may not be the same.
...
Nomenclature of Ionic and Covalent Compounds.