I think this do what you need,
use strict; use warnings; my @input = <DATA>; chomp @input; my ($max, $s_max) = sort { $b<=>$a} @input; print $max,$",$s_max,$/; __DATA__ 0.2430 0.0830 0.1320 0.0920 0.0180 0.0880 0.3440
Regards,
Murugesan Kandasamy
use perl for(;;);
In reply to Re: extracting the largest values
by murugu
in thread extracting the largest values
by Angharad
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |