Hi, I have gone for the following code:
my %avs_dev = map{
$_ => [mean($hoa{$_}), dev($hoa{$_})]
} keys %hoa;
for (sort {$avs_dev{$a}[0] <=> $avs_dev{$b}[0]} keys %avs_dev) {
print "$_, $avs_dev{$_}[0], $avs_dev{$_}[1]\n";
}
I have never used MAP before... it looks handy!
Works a treat.
Thanks to Jeff 'japhy' Pinyan & Wiggins d'Anconia
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
<http://learn.perl.org/> <http://learn.perl.org/first-response>
