import logging
logging.basicConfig(level=logging.INFO, format='%(asctime)s:%(name)s:%(levelname)s: %(message)s')
class Test(object):
@staticmethod
def is_leapYear(year):
leap_year = False
if (year % 4) == 0:
if (year % 100) == 0:
if (year % 400) == 0:
leap_year = True
else:
leap_year = True
return leap_year
if __name__ == "__main__":
test = Test()
is_leap = test.is_leapYear(2001)
logging.info("is_leap: %s" % is_leap)