Further explanation
The Atomic Number (Z) indicates the number of protons in an atom of an element. If the atom is neutral then the number of protons will be equal to the number of electrons. So the atomic number can also indicate the number of electrons.
Mass Number (A) = Number of protons + Number of Neutrons
Atomic Number (Z) = Mass Number (A) - Number of Neutrons
Atomic number = number of protons = number of electrons ⇒ neutral atoms
Atomic number - positive charge = number of electrons ⇒ cation
Atomic number + negative charge = number of electrons ⇒ anion
You can also see the periodic system
A. Indium (In)
B. proton = electron = 27
C. proton = electron = 73
D. proton = electron = 49
E=F. atomic mass - neutron = 137 - 81 = 56
G. atomic mass-proton = 115- 49 = 66
H. 181-73 = 108