good chemistry is complicated, and a little bit messy -LW |
|
PerlMonks |
Re: A date calculationby chrism01 (Friar) |
on Dec 19, 2007 at 01:15 UTC ( [id://657772]=note: print w/replies, xml ) | Need Help?? |
As per funkymonk's orig post, it's trying to calc the first of the (next) mth, by adding enough days to get to the end of the curr mth (calc in seconds). It's actually an off-by-one error (in this case off by 1 day). As mentioned, you should use a Date:: module to avoid fiddly details like different mth lengths and leap yrs.
In Section
Seekers of Perl Wisdom
|
|