Which type of chemical bond forms when electrons are either gained or lost by an atom?

ionic