def is_leap_year(year):
    """Returns whether a given year was a leap year"""

    #  "There is a leap year every year whose number is perfectly divisible by four -
    #  except for years which are both divisible by 100 and not divisible by 400."
    #  quoted from Western Washington University
    #  https://www.wwu.edu/astro101/a101_leapyear.shtml

    if year % 100 == 0:  # if year is a century year, an additional check is required (see above)
        if year % 400 == 0:  # centuries must also be divisible by 400
            return True
        return False
    if year % 4 == 0:
        return True
    return False