The chemical formula of sodium oxide is Na2O, and the chemical formula of sodium peroxide is Na2O2. It can be known that sodium peroxide molecules have one more oxygen atom than sodium oxide molecules.
It can be judged that the molecular composition of barium peroxide is one o atom more than that of barium oxide BaO, and the chemical formula of barium peroxide can be expressed as BaO 2;;
So choose B.