From a4dba3f2c51083bd2020e8e439a9a28e91a78444 Mon Sep 17 00:00:00 2001 From: calebhf1 <62314190+calebhf1@users.noreply.github.com> Date: Tue, 24 Sep 2024 15:05:10 +0000 Subject: [PATCH] Complete leap.py --- leap/leap.py | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/leap/leap.py b/leap/leap.py index 50fd034..45a8d43 100644 --- a/leap/leap.py +++ b/leap/leap.py @@ -1,2 +1,12 @@ def leap_year(year): - pass + if year % 400 == 0: + return True + elif year % 100 == 0: + return False + elif year % 4 == 0: + return True + else: + return False + + +print(leap_year(1999)) \ No newline at end of file