tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "mech" <m...@rz.fh-augsburg.de>
Subject RE: bug in java api? (ot)
Date Thu, 06 Feb 2003 12:09:05 GMT
Indeed 2000 was a leap year with 29th of Feb.

Every year that can be divided by four is a leap year, except it can be
divided by 100 than it's not. 
But if it can be divided by 400 then it is a leap year again. ;-)

So because of the last rule, 2000 was a leap year and the API is
correct...

> -----Original Message-----
> From: Daniel Brown [mailto:gmy11@blueyonder.co.uk] 
> Sent: Donnerstag, 6. Februar 2003 13:03
> To: Tomcat Users List
> Subject: RE: bug in java api? (ot)
> 
> 
> But 2000 *was* a leap year...?
> 
> http://world.std.com/~dpbsmith/leapyearfaq.txt
> 
> > -----Original Message-----
> > From: Felipe Schnack [mailto:felipes@ritterdosreis.br]
> > Sent: 06 February 2003 11:50
> > To: Tomcat Users List
> > Subject: bug in java api? (ot)
> >
> >
> >   Take a look at the following code
> >
> > GregorianCalendar cal = (GregorianCalendar)Calendar.getInstance();
> > cal.set(2000, Calendar.FEBRUARY, 1); 
> > System.out.println(cal.isLeapYear(2000));
> >
> >   Shouldn't "false" be printed on the screen? I see "true" 
> here in my 
> > machine :-)
> >
> > --
> >
> > Felipe Schnack
> > Analista de Sistemas
> > felipes@ritterdosreis.br
> > Cel.: (51)91287530
> > Linux Counter #281893
> >
> > Centro Universitário Ritter dos Reis http://www.ritterdosreis.br
> > ritter@ritterdosreis.br
> > Fone/Fax.: (51)32303341
> >
> >
> > 
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> >
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message