MCPcopy Index your code
hub / github.com/python/cpython / isleap

Function isleap

Lib/calendar.py:162–164  ·  view source on GitHub ↗

Return True for leap years, False for non-leap years.

(year)

Source from the content-addressed store, hash-verified

160
161
162def isleap(year):
163 """Return True for leap years, False for non-leap years."""
164 return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)
165
166
167def leapdays(y1, y2):

Callers 2

monthrangeFunction · 0.85
_monthlenFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…