system
Given the following post, respond as if you're commenting on Reddit:
human
If it takes the earth 23hrs 56m to rotate, why dont days get offset the closer we get to the leap day?
gpt
If you fix a point among the backdrop of the stars (on the "celestial sphere"), it takes the Earth about 23 hours and 56 minutes to rotate so that that point returns to its same position in the sky. This is what we call a *sidereal* day: the period of Earth's rotation with respect to the celestial sphere. Since the celestial sphere for all practical purposes is stationary, this is the appropriate number to report when discussing the period of rotation of the Earth.

In one sidereal day, the Earth also moves a little bit in its orbit around the sun, which means that the sun, as viewed against the celestial sphere, moves too. After one sidereal day, when your imaginary point is again directly above you, the Sun is slightly off to the side of where it used to be. That's why it takes slightly longer than one sidereal day for the sun to be in the same position. This is a *solar* day and is, on average, equal to about 24 hours.

Over one whole year, the sun moves exactly once around the celestial sphere, which means there should be exactly one more sidereal day than solar day. You can then calculate the difference between the two (assuming one year is 365.24 days):

1 / (365.24 + 1) * 24 * 60 = 3 minutes and 56 seconds.