calendar_lib/year.py
def year_starts_on(year: int) -> int:
    """
    Given a year X => 1582, return the weekday of Jan 1st X
    """
    leap_years = leap_years_between(1583, year)
    # leap_years = leap_between(1583, year)
    years = (year - 1583)
    # add offset because 1583 started on a Saturday = WEEKDAYS[5]
    difference = (leap_years + years + 5)
    return difference % 7

    Given a year X => 1582, return the weekday of Jan 1st X
    
Given a year X => 1582, return the weekday of Jan 1st X
Given a year X = > 1582 return the weekday of Jan 1st X
def year_starts_on(year: int) -> int:
    leap_years = leap_years_between(1583, year)
    years = (year - 1583)
    difference = (leap_years + years + 5)
    return difference % 7
def year_starts_on ( year : int ) -> int : leap_years = leap_years_between ( 1583 , year ) years = ( year - 1583 ) difference = ( leap_years + years + 5 ) return difference % 7
Given a year X => 1582, return the weekday of Jan 1st X
Given a year X = > 1582 return the weekday of Jan 1st X
"""
    Given a year X => 1582, return the weekday of Jan 1st X
    """ # leap_years = leap_between(1583, year) # add offset because 1583 started on a Saturday = WEEKDAYS[5]
year
int