What does the subscript 2 indicate in the formula O2?

Each oxygen atom is sharing two electrons.

There are two valence electrons in the molecule.

There are two atoms in the molecule.

Oxygen transferred 2 electrons to form the bond.

There are two atoms in the molecule.