in reply to Re: If any element-in-array comparision
in thread If any element-in-array comparision
use List::UtilsBy qw(max_by); my @list=(0.03,0.04,0.01); my $max=max_by {$_} @list; print "Maximum of ",join(',',@list)," is $max\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: If any element-in-array comparision
by fisher (Priest) on Jan 27, 2012 at 16:29 UTC | |
by naturalsciences (Beadle) on Jan 27, 2012 at 16:51 UTC | |
by fisher (Priest) on Jan 27, 2012 at 17:07 UTC | |
by naturalsciences (Beadle) on Jan 27, 2012 at 17:34 UTC |