In the example above, change my @sorted = sort {str2time($a) <=> str2time($b)} @dates; to
my %cache; my @sorted = sort {($cache{$a} ||= str2time($a)) <=> ($cache{$b} ||= str2time($b)) } @dates;
In reply to Re: Re: Re: Date comparison
by dws
in thread Date comparison
by bengmau
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |