how do you figure out how many electrons are in an element's valence shell?
For neutral atoms, the number of valence electrons is equal to the atom's main group number. The main group number for an element can be found from its column on the periodic table. For example, carbon is in group 4 and has 4 valence electrons. Oxygen is in group 6 and has 6 valence electrons.