If you were sorting without a custom comparison block, the sort solution could be faster for small data sets, but as this is not the case... and anyway, you can grep:
for my $file (grep { $hash{$_}{Size} > $sizeLimit } @path) { delete_file($file); }
In reply to Re: Which one is best for optimization
by salva
in thread Which one is best for optimization
by luckypower
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |