where does the length of a second come from
Second Though the historical definition of the unit was based upon this division of the Earth's rotation cycle, the formal definition in the International System of Units SI is a much steadier timekeeper: 1 second is defined to be exactly 9 192 631 770 cycles of a Caesium atomic clock.[1][2][3] Because the Earth's rotation varies and is also slowing ever so slightly, a leap second is added to clock time[nb 2] to keep clocks in sync with Earth's rotation.