The period number in the long form of the periodic table is equal to
The maximum number of shells are shown by the maximum principle quantum number which is equal to the period number of the periodic table.
For example, Electronic Configuration of Na is 1s22s22p23s1
As the last electron is present in the third shell, therefore sodium lies in the third period.