Atoms are not sentient. They undergo chemical bonding and chemical reactions in order to have lower energy, which makes them stable. Typically this means either sharing electrons to get an octet of electrons, or transferring electrons so they get an octet of electrons. This is not a conscious decision on their part.
When the atom has 8 valence electrons.
A chlorine atom would gain one electron to become an ion because it tends to achieve a stable electron configuration by having a full outer shell of electrons.
It'll have to lose two to have a stable octet.
Nucleous
4
isotope
to become stable, it will gain an electron from a metallic atom otherwise it will mutually share electron(s) with another non - metallic atom, or even with itself
It can do either, depending on it's state previous to losing neutrons. Generally if an atom is shedding neutrons it is doing so to become more stable.
The only way a carbon atom becomes stable is if they gain or lose electrons. Typically carbon will bond with other elements to do this.
It becomes most stable when its nucleus is filled, not when it is filling it.
2
An oxygen atom requires 8 electrons to become stable because it has 6 electrons in its valence shell and needs 2 more to complete it. This is achieved by forming chemical bonds with other atoms, such as sharing electrons in covalent bonds.