Um... no. readdir() is unsorted and you don't want to be making redundant stat() calls (being expensive n' all).
my @dirfiles = map { $_->[0] } sort { $_->[1] <=> $_->[1] } map { [ $_, stat $_ ] } grep( not m/^\.\.?$/, readdir ORDERS);
In reply to Re: READDIR - Sort by Time?
by diotalevi
in thread READDIR - Sort by Time?
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |