How about:
my @files = sort {(stat $a)[9] <=> (stat $b)[9]} glob "$mask*"; print $files[$position - 1], "\n";
In reply to Re: Finding a file by age (Newest First)
by pbeckingham
in thread Finding a file by age (Newest First)
by ChuckularOne
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |