Question: how many valence electrons do atoms of oxygen and sulfur?
Answer: The Group 6A elements have six valence electrons in their highest-energy orbitals (ns2np4). This is only two electrons away from having a full octet of eight electrons, so many of these elements form anions having -2 charges: oxide, O2-; sulfide, S2-, selenide, Se2-, etc.