Python Program to Check Leap Year

  • If a year is perfectly divisible by 4, leaving no remainder, the year will be a leap year. If it gives any reminder, then that year won’t be a leap year. For example, 1999 is not a leap year.
  • If any year is perfectly divisible by 4 except for the year ending with 00 and perfectly divisible by 100, then the year won’t be a leap year. For example, 1900 is not a leap year.
  • If any year is ending with 00 and perfectly divisible by 400, then the year will be a leap year. For example, 2000 is a leap year.

--

--

--

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Graalvm, polyglot VM written in Java

Siri just made your life automated: introducing shortcuts

Lets Create Obstacle Avoiding Car using Arduino

Front view of the car

Algorithm_Leetcode

Learn Servlet-JSP By Building A Social Network Website — Part I

How to pick a random element from an array (Swift)

Things That May Hold You Back From Unlocking Your Full Potential as a Developer

Resize a PDF Document using Java

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Amansingh Javatpoint

Amansingh Javatpoint

More from Medium

Advantages and disadvantages of python programming language

Python Functions…

How to Port Python on iMX6Q Development Board

How to prank your friends with this python wallpaper locker! — StackZero