how is the number of electrons and protons related
The number of protons is exactly the same as the number of electrons in an atom.