Final answer:
A mass spectrometer detects the mass of ionized molecules. It separates and detects charged particles based on their mass-to-charge ratio, creating a mass spectrum.
Step-by-step explanation:
A mass spectrometer detects the mass of ionized molecules. In a mass spectrometer, the sample is vaporized and exposed to a high-energy electron beam, causing the atoms or molecules to become charged. These charged particles are then separated and detected based on their mass-to-charge ratio, creating a mass spectrum. The height of each peak in the mass spectrum is proportional to the fraction of ions with a specific mass-to-charge ratio.