in reply to How do I find today's date?

Here's a complete little program:
use Time::localtime; my $tm = localtime; printf "The current date is %04d-%02d-%02d\n", $tm->year+1900, ($tm->m +on)+1, $tm->mday; printf "The current time is %02d:%02d:%02d\n", $tm->hour, $tm->min, $t +m->sec;

Replies are listed 'Best First'.
Re: Answer: How do I find today's date?
by davorg (Chancellor) on Sep 03, 2001 at 15:33 UTC