You need to write oxygen's electron configuration to help you with that.
This means that a neutral oxygen atom will have a total of eight electrons surrounding its nucleus. Oxygen's electron configuration will look like this
#"O: " 1s^2 color(red)(2)s^2 color(red)(2)p^4#
Valence electrons are located in the outermost energy shell of an atom. In the case of oxygen, its outermost shell corresponds to
In this case, helium is that noble gas
#"He: " 1s^2#
This mean's that oxygen's nmoble gas shorthand will be
#"O: " ["He"] 2s^2 2p^4#
Compare this with your set of values
#A = 2 ->#the second energy level
#B = 2 ->#two electrons on the 2s-subshell
#C = 4 ->#four electrons on the 2p-subshell
As you can see, oxygen has six electrons in its outermost shell, which is equivalent tosaying that it has six valence electrons.