Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions Hactoberfest2020/Write_a_function.py

This file was deleted.

25 changes: 25 additions & 0 deletions Hactoberfest2020/leapYear_Check.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
year = input("Type the year which you want to check...\n")

def checkLeapYear(year):
leapYear = False
Year = int(year)
if Year % 4 == 0:
if Year % 100 == 0:
if Year % 400 == 0:
leapYear = True
elif Year % 400 != 0:
leapYear = False

elif Year % 100 != 0:
leapYear = True
elif Year % 400 == 0:
leapYear = True

return leapYear

isLeapYear = checkLeapYear(year)
print(isLeapYear)
if isLeapYear == True:
print(f"yes {year} is a leap Year.")
else:
print(f"No, {year} is not a leap Year.")