Silver has one valence electron and oxygen has 6 electrons in the outermost shell. Ionic bonds are formed by the transfer of electrons from a metal to a non metal.
atoms are most stable when they complete their outermost shell and complete the octet. This is when their s and p subshells in the outermost shell are complete, eight electrons hence complete octet.
silver has one valence electron so to become stable it will lose that valence electron and transfer it to oxygen. Oxygen has 6 valence electrons so to become stable it needs 2 electrons to complete its octet.
One silver atom gives one electron each, since oxygen needs 2 electrons ,
2 silver atoms are needed to form an ionic bond.
Ag will become cation - Ag⁺ and Oxygen will become an anion - O²⁻
ionic bond is formed due to the electrostatic attraction between oppositely charged ions
ionic compound - Ag₂O
2 silver atoms needed for one oxygen