Send white light through a cool, low-pressure gas and disperse what comes out: the continuous rainbow reappears, but scored by thin dark lines. The gas has removed certain wavelengths from the passing light. Such a spectrum — a continuous background minus a set of lines — is an absorption spectrum.
Examples
Example 2.17 (A flask of sodium vapor)
White light crosses a flask containing cool sodium vapor. The transmitted spectrum is a full rainbow with one dark line at — precisely where a sodium lamp shines brightest. Looking at the flask from the side in a dark room, one sees the stolen light re-emitted: a faint yellow-orange gleam at that same wavelength.