Substitution - Elimination

HO- is a very common nucleophile. Remember a nucleophile is a species that
desires to donate its electron density to another compound. In an SN2
reaction, the electron density of the HO- molecule (shown in red) will
attack the backside of a carbon-X bond (SN2) or a carbocation
(SN1). HO- is also a strong base so it can remove a proton.
(E1 or E2).

Methyl chloride can be involved in SN2 reactions. A nucleophile
(HO- , for example) will attack the backside of the carbon connected to
the Cl-, and the Cl- will be forced out as a leaving group. Notice that
the area of high electron density on the nucleophile (red area) will attack
the area of low electron density on the methyl chloride molecule (blue
area). This backside attack will cause an inversion in the stereochemistry.

Anti-periplanar geometry is required in E2 reactions. That is, an elimination
will occur (or a double bond will be formed) only if the base attacks the
hydrogen that is in the same plane as the leaving group. This antiperiplanar
geometry allows the orbital to line up as the pi bond is forming.