First get your file into an array thru Tie::File, then:
use Data::Dumper; my @a = ("image1.jpg:100:250:1062352538", "image2.jpg:650:175:10623403 +59"); @a = sort {(split(":", $a))[-1] <=> (split(":", $b))[-1]} @a; print Dumper(\@a);
In reply to Re: sorting entires by date
by pg
in thread sorting entires by date
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |