The second map can be shortened up a bit. I'm just making what's going on there a little more obvious...@r=qw( 1:00AM 2:45PM 8:30AM 3:15PM 6:15PM ); @t=map { $_->[0] } sort { $a->[1] <=> $b->[1] } map { $a=$_; s/://; s/(\d+)(\w)M/$1+($2 eq "P"?1200:0)/e; [ $a, $_ ] } @r; # @t has your sorted times.
In reply to Re: Sorting Times
by clintp
in thread Sorting Times
by mt2k
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |