# take input
      year = int(input('Enter a year: '))
      # check leap year or not
      if (year % 400) == 0:
          print('{0} is a leap year'.format(year))
      elif (year % 100) == 0:
          print('{0} is not a leap year'.format(year))
      elif (year % 400) == 0:
          print('{0} is a leap year'.format(year))
      else:
          print('{0} is not a leap year'.format(year))
      

      Python language logo
      Leap Year

      beginner
      logic

      To verify if the given year is a leap year or not

      0 Comments

        Add Comment

        Log in to add a comment

        Codiga - All rights reserved 2022.