Task

Determine whether a given year is a leap year in the Gregorian calendar.



See also

 Leap year (wiki)


var isLeapYear = function (year) { return (year % 100 === 0) ? (year % 400 === 0) : (year % 4 === 0); };