From 0c4a04a9d8cda90a0db27174c300acd25b5c71ed Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebastian=20G=C3=B6ttschkes?= Date: Tue, 16 Jan 2024 16:04:52 +0100 Subject: [PATCH] Fix linting issues for leap in Python --- python/leap/leap.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/python/leap/leap.py b/python/leap/leap.py index e143591..9b11a1b 100644 --- a/python/leap/leap.py +++ b/python/leap/leap.py @@ -1,2 +1,5 @@ +"""Function to calculate leap year.""" + def leap_year(year): - return True if year % 4 == 0 and (year % 100 != 0 or year % 400 == 0) else False + """Function to calculate leap year.""" + return year % 4 == 0 and (year % 100 != 0 or year % 400 == 0)