Expressions

Leap Year

Levels

A coworker has a program that's meant to tell you the number of days in a year. Most years have 365 days, except leap years, which have 366. Here is the code she has:

The code has a slight bug in it. The code checks if the year is divisible by 4. If it is it treats it as a leap year.

...
Experiments are available to members.
Become a Member