A combo of Date::Calc and sprintf works for me.
use Date::Calc qw(:all); my ($year,$month,$day, $hour,$min,$sec) = Today_and_Now(); my $date = sprintf ("%02d-%02d-%d", $month,$day,$year); my $time= sprintf ("%02d:%02d:%02d", $hour,$min,$sec);
In reply to Re: best way to write code
by bradcathey
in thread best way to write code
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |