The mass number is used to calculate the number of protons and neutrons in an atom. It is the total count of these two particles in the nucleus. Since the number of protons defines the element, and the number of neutrons can vary, the mass number helps determine how many neutrons are present by subtracting the atomic number (number of protons) from the mass number.