In this kata you should simply determine, whether a given year is a leap year or not. In case you don't know the rules, here they are:

* years divisible by 4 are leap years
* but years divisible by 100 are **not** leap years
* but years divisible by 400 are leap years

Additional Notes:

* Only valid years (positive integers) will be tested, so you don't have to validate them

Examples can be found in the test fixture.

Difficulty: EASY
Starter code: def isLeapYear(year):
	

Solutions:
def isLeapYear(year):
	return year % 100 != 0 and year % 4 == 0 or year % 400 == 0


from calendar import isleap as isLeapYear


def isLeapYear(year):
	return year % 4 is 0 and year % 100 is not 0 or year % 400 == 0


import calendar

def isLeapYear(year):
	return calendar.isleap(year)


isLeapYear = lambda y: (not y % 4) * bool(y % 100 + (not y % 400))


def isLeapYear(year):
	if year % 400 == 0 or (year % 4 == 0 and (not year % 100 == 0)):
		return True
	else:
		return False


isLeapYear = __import__('calendar').isleap


def is_leap_year(year):
	return year % 100 and (not year % 4) or not year % 400
isLeapYear = is_leap_year


def isLeapYear(year):
	return year % 4 == 0 and (not (year % 100 == 0 and (not year % 400 == 0)))