Feedback on: irt.org FAQ Knowledge Base Q228
Worth:
Worth reading
Comments:
your function to check for a leap year is incorrect, it does not handle years correctly that are multiples of 100, your function returns at the wrong point.
This might be better:
function isLeapYear (Year) {
if (((Year % 4)==0) && ((Year % 100)!=0) || ((Year % 400)==0)) {
return (true);
}
else {
return (false);
}
Just my $ 0.02
Worth:
Worth reading
Length:
Technical:
Comments:
There is a typo in the document.write statement. To get the current
year, you need: today.getYear() (The () are missing)