in reply to sort hash by value
for (@reportnL[0..4]) { print "$_\n"; }
Your use of an array slice here seems a little unusual, not incorrect but not the way I suspect most would approach the task. I would perhaps do
for ( 0 .. 4 ) { print qq{$reportnL[$_]\n}; }
or, more probably
print qq{$reportnL[$_]\n} for 0 .. 4;
I hope this is of interest.
Cheers,
JohnGG
|
|---|