[REBOL] Re: One-Liners
From: Al:Bri:xtra at: 18-Apr-2003 8:35
> I was reading the One-Liners page in RebolTech web Site, and I've just a
very little remark on a script on Andrew. In fact year 2000 is not a
leapyear, because all years that multiply 400 are not leapyear, in order to
approach to the real number of days (365,2422) in a year. With this system,
it's approached to 365,2425
My Windows XP clock calendar indicates that year 2000 has 29 days in
February. This means that 2000 IS a leap year.
>> leapyear? 1/1/2000
Leapyear?: function [
"Returns true for a leap year."
Date [date!] "The date to check."
] [Year] [
0 = remainder Year 4
0 <> remainder Year 100
0 = remainder Year 400
** Syntax Error: Invalid date -- 30/2/2000
** Near: (line 1) 30/2/2000
Rebol also agrees that there is 29 days in February, 2000.
Any other opinions?
ICQ: 26227169 http://valley.150m.com/