MCPcopy Index your code
hub / github.com/RustPython/RustPython / yeardays2calendar

Method yeardays2calendar

Lib/calendar.py:310–318  ·  view source on GitHub ↗

Return the data for the specified year ready for formatting (similar to yeardatescalendar()). Entries in the week lists are (day number, weekday number) tuples. Day numbers outside this month are zero.

(self, year, width=3)

Source from the content-addressed store, hash-verified

308 return [months[i:i+width] for i in range(0, len(months), width) ]
309
310 def yeardays2calendar(self, year, width=3):
311 """
312 Return the data for the specified year ready for formatting (similar to
313 yeardatescalendar()). Entries in the week lists are
314 (day number, weekday number) tuples. Day numbers outside this month are
315 zero.
316 """
317 months = [self.monthdays2calendar(year, m) for m in Month]
318 return [months[i:i+width] for i in range(0, len(months), width) ]
319
320 def yeardayscalendar(self, year, width=3):
321 """

Callers 2

formatyearMethod · 0.80
formatyearMethod · 0.80

Calls 2

monthdays2calendarMethod · 0.95
lenFunction · 0.85

Tested by

no test coverage detected