Stars are classified using the letters O, B, A, F, G, K, and M based on their spectral characteristics, particularly the intensity of hydrogen lines, which were initially used by Professor Draper in the late 1800s. The classification reflects a sequence from the hottest stars (O) to the coolest (M), with each letter representing a specific temperature range and spectral features. Over time, the classification system evolved as astronomers gained a better understanding of stellar atmospheres and the significance of effective temperatures. Some letters were dropped as they represented rare stars, leading to the current classification scheme. The letters serve as a mnemonic device for remembering the order of stellar types, though their original meaning has shifted to focus more on temperature than spectral line intensity.