Learn R Programming

s2dv (version 2.1.0)

LeapYear: Checks Whether A Year Is Leap Year

Description

This function tells whether a year is a leap year or not.

Usage

LeapYear(year)

Value

Boolean telling whether the year is a leap year or not.

Arguments

year

A numeric value indicating the year in the Gregorian calendar.

Examples

Run this code
print(LeapYear(1990))
print(LeapYear(1991))
print(LeapYear(1992))
print(LeapYear(1993))

Run the code above in your browser using DataLab