1 / 9

Leap Years

Leap Years. What is a leap year?. In most years, February has 28 days. Approximately every 4 years, February has 29 days. The years in which February has 29 days are called leap years . What is a “century” year?. A “century” year is any year that is evenly divisible by 100

keon
Download Presentation

Leap Years

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Leap Years

  2. What is a leap year? • In most years, February has 28 days. • Approximately every 4 years, February has 29 days. • The years in which February has 29 days are called leap years.

  3. What is a “century” year? • A “century” year is any year that is evenly divisible by 100 • Examples1800, 1900, 2000, etc. are evenly divisible by 100 so they are “century” years

  4. How can you know if a year is a leap year? • The rules to determine if a specific year is a leap year or not depend on : whether the year is a century year or a non-century year.

  5. “Century” Years • A century is a leap year if it is divisible by 400 • Examples: The year 1800 is NOT a leap year since it is NOT evenly divisible by 400 1800 / 400 = 4.5The year 2000IS a leap year since it IS evenly divisible by 400 2000 / 400 = 5

  6. Non-Century Years • A non-century year is a leap year if it is evenly divisible by 4 • Examples: The year 1995 is NOT a leap year since it is NOT evenly divisible by 4 1995/ 4 = 498.75The year 1996IS a leap year since it IS evenly divisible by 4 1996 / 4 = 499

  7. Using the IF statement

  8. How to determine if it is a century year? If year Mod 100 = 0 Then ‘century yearElse ‘ non-centry yearEnd If

  9. How do you determine if a year is leap year If year Mod 100 = 0 Then ‘century year If year Mod 400 = 0 ‘ leap year End IfElse ‘ non-centry year If year Mod 4 = 0 ‘ leap year End IfEnd If

More Related