Account for the fact that the fourth period has 18 and not 8 elements

The first element of fourth period is potassium (Z = 19) having electronic configuration 1${{s}^{2}}$2${{s}^{2}}$2${{p}^{6}}$3${{s}^{2}}$3${{p}^{6}}$4${{s}^{1}}$. Thus it start with the filling of 4s orbital. After the filling of 4s orbital, instead of 4p orbitals, there starts the filling 3d orbitals. This is in keeping with the fact that 3d orbitals have less energies than 4p orbitals. Thus 10 elements are built up by the filling of 3d orbitals. After the filling of 3d orbitals, 4p orbitals are filled and that process is completed at krypton [Kr, Z 36]. Hence the fourth period consists up of 18 and not 8 elements.