in reply to Re: extract month and year from localtime
in thread extract month and year from localtime

This kind of construct

sub{ 1+shift, 1900+shift }->((localtime time)[4,5])

I have been missing for a long time. Many many thanks!

Replies are listed 'Best First'.
Re^3: extract month and year from localtime
by davido (Cardinal) on Feb 21, 2014 at 08:37 UTC

    Yeah, I was kind of glad I remembered it. It seems too often we end up creating some temporary variables to receive and decorate values, when we can do our decorating inline with an immediate-use anonymous sub.


    Dave