Mass number = number of protons + number of neutrons
The number of protons in the nucleus of an atom of phosphorus is equal to the atomic number of phosphorus, which is 15. If an atom of phosphorus has 17 neutrons, then the mass number would be 15 protons + 17 neutrons = 32. Thus, the correct answer choice here is B.