The method without any external modules:
my $mmddyyyy = sprintf "%02d/%02d/%d",
(localtime)[4] + 1, # months
(localtime)[3], # days
(localtime)[5] + 1900; # years
The more maintainable way:
use POSIX qw( strftime );
my $mmddyyyy = strftime("%m/%d/%Y", localtime);
The POSIX module comes with the standard distribution of Perl, so should never need installing separately. As a result it is very fast and extremely portable.
Best wishes,
Dave Cardwell.
http://davecardwell.co.uk/perl/