The number of electrons gained by the anode is equal to the number of electrons donated by the cathode.