2100 is not a leap year
- Year
- 2,100
Result2100 is not a leap year. It is divisible by 100 but not by 400, which is the exception most people forget.
divisible by 100 but not 400: the century exception
Open this exampleWhether a year is a leap year, including the century rule that catches people out. 1900 was not a leap year and 2000 was.
Also called: is it a leap year, leap year test.
2100 is not a leap year. It is divisible by 100 but not by 400, which is the exception most people forget.
A tropical year is about 365.2422 days, so adding a day every four years overshoots slightly. Skipping the century years corrects too far, and restoring every fourth century corrects back. The remaining error is about one day in 3,200 years.
leap = (year %% 4 == 0 and year %% 100 != 0) or year %% 400 == 0Each of these is asserted on every build. If a change to the engine ever moved one of these answers, the build would fail before the page could print it.
Result2100 is not a leap year. It is divisible by 100 but not by 400, which is the exception most people forget.
divisible by 100 but not 400: the century exception
Open this exampleResult2000 is a leap year, so it has 366 days.
divisible by 400: the exception to the exception
Open this exampleResult2024 is a leap year, so it has 366 days.
ordinary four-year rule
Open this example