hi If you would like to work with a cleaner perl, try: http://search.cpan.org/~mschwern/perl5i-v2.12.0/lib/perl5i.pm it is slower but it is beautiful.
other way is to use Classes like DateTime directly Best Regards MArcos On Tue, Jan 28, 2014 at 8:32 AM, Luca Ferrari <fluca1...@infinito.it> wrote: > Hi all, > often I find myself writing something like the following to get the > "human" date: > > my ($day, $month, $year) = (localtime())[3..5]; > $month++, $year += 1900; > print "\nToday is $month / $day / $year \n"; > > > I was wondering if there's a smarter pattern to get the right value in > one single line. At least there's no simple "map" I can think of. > > Thanks, > Luca > > -- > To unsubscribe, e-mail: beginners-unsubscr...@perl.org > For additional commands, e-mail: beginners-h...@perl.org > http://learn.perl.org/ > > > -- Marcos Rebelo http://www.oleber.com/ Webmaster of http://perl5notebook.oleber.com