  We present optical photometry and spectroscopy of the Type IIn supernova (SN)
2021qqp. Its unusual light curve is marked by a long precursor for $\approx300$
days, a rapid increase in brightness for $\approx60$ days, and then a sharp
increase of $\approx1.6$ mag in only a few days to a first peak of $M_r \approx
-19.5$ mag. The light curve then declines rapidly until it re-brightens to a
second distinct peak of $M_r \approx -17.3$ mag centered at $\approx335$ days
after the first peak. The spectra are dominated by Balmer lines with a complex
morphology, including a narrow component with a width of $\approx 1300$ km
s$^{-1}$ (first peak) and $\approx 2500$ km s$^{-1}$ (second peak) that we
associate with the circumstellar medium (CSM) and a P Cygni component with an
absorption velocity of $\approx 8500$ km s$^{-1}$ (first peak) and $\approx
5600$ km s$^{-1}$ (second peak) that we associate with the SN-CSM interaction
shell. Using the luminosity and velocity evolution, we construct a flexible
analytical model, finding two significant mass-loss episodes with peak mass
loss rates of $\approx 10$ and $\approx 5\,M_{\odot}$ yr$^{-1}$ about $0.8$ and
$2$ yr before explosion, respectively, with a total CSM mass of $\approx
2-4\,M_{\odot}$. We show that the most recent mass-loss episode could explain
the precursor for the year preceding the explosion. The SN ejecta mass is
constrained to be $\approx 5-30\,M_{\odot}$ for an explosion energy of $\approx
(3-10)\times10^{51}$ erg. We discuss eruptive massive stars (luminous blue
variable, pulsational pair instability) and an extreme stellar merger with a
compact object as possible progenitor channels.
