#K79672. Determine Whether a Year is a Leap Year

    ID: 35361 Type: Default 1000ms 256MiB

Determine Whether a Year is a Leap Year

Determine Whether a Year is a Leap Year

Given an integer year, determine whether it is a leap year.

A year is a leap year if either:

  • It is divisible by 4 but not divisible by 100, or
  • It is divisible by 400.

For example, the year 2020 is a leap year, while 1900 is not.

inputFormat

The input consists of a single integer, representing the year. The year satisfies (1 \leq year \leq 10000). The input is given via standard input.

outputFormat

Output a single line containing either "Leap Year" if the given year is a leap year or "Not a Leap Year" otherwise. The output is printed to standard output.## sample

2020
Leap Year