Skip to content

Commit

Permalink
problem3 updated
Browse files Browse the repository at this point in the history
  • Loading branch information
well-balanced committed Oct 23, 2019
1 parent e0280b4 commit b54a229
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions problem_3.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
def is_leap(year):
leap = False
if year<1900 and pow(10,5)<year:
return leap
if year%400 == 0:
leap = True
return leap
if year%100==0:
leap = False
elif year%4==0:
leap = True
return leap

year = int(input())
print(is_leap(year))

0 comments on commit b54a229

Please sign in to comment.