Calcium is the 20th element in the periodic table. If the substance is neutral this means that the number of elements is equal to the number of protons. The assigning of the numbers in the electron configuration can be made using the Aufbau Principle.
The principle states that the electrons occupy the orbitals with lowest energy level. Having said this, the electron configuration therefore of the calcium is,
Ca(20) = 1s²2s²2p⁶3s²3p⁶4s²