import calendar # to set the first weekday to SUNDAY. calendar.setfirstweekday(calendar.SUNDAY) print(calendar.month(2020, 10 ))