Sha256: ab231b39dce1f12f12c8f2c76087f9dd8ebbb716cb2ac5914d8ff97188e41f04
Contents?: true
Size: 424 Bytes
Versions: 255
Compression:
Stored size: 424 Bytes
Contents
'use strict'; /** * Represents a year to check whether is leap or not * * @param {number} year * Numeric year. */ function Year(year) { this.year = year; } /** * Whether given year is a leap year. * * @return {boolean} * Whether given year is a leap year. */ Year.prototype.isLeap = function () { return (this.year % 400 == 0) || ((this.year % 4 == 0) && (this.year % 100 != 0)); } module.exports = Year;
Version data entries
255 entries across 255 versions & 1 rubygems