MCPcopy Create free account
hub / github.com/catboost/catboost / LeapYearCount

Function LeapYearCount

util/datetime/systime.cpp:99–101  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

97 constexpr ui32 FOUR_CENTURY_YEARS = 400;
98
99 constexpr ui32 LeapYearCount(ui32 years) {
100 return years / 4 - years / 100 + years / 400;
101 }
102
103 constexpr ui32 FOUR_CENTURY_DAYS = FOUR_CENTURY_YEARS * DAYS_IN_YEAR + LeapYearCount(FOUR_CENTURY_YEARS);
104

Callers 4

systime.cppFile · 0.85
FindYearWithin4CenturiesFunction · 0.85
GmTimeRFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected