########################################
# A year is a leap year if the following:
# 1) it is a multiple of 4 AND
# 2) a century must be a multiple of 400 
#
# 2000 is a leap year but 1900 is not.
########################################

year = 1900

if((year %% 4) == 0) {
    if((year %% 100) == 0) {
        if((year %% 400) == 0) {
            print(paste(year,"is a leap year"))
        } else {
            print(paste(year,"is not a leap year"))
        }
    } else {
        print(paste(year,"is a leap year"))
    }
} else {
    print(paste(year,"is not a leap year"))
}

