Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Algorithm concerns

by I0 (Priest)
on May 03, 2002 at 23:14 UTC ( [id://163939]=note: print w/replies, xml ) Need Help??


in reply to Ranking people by weight and height

@height = (10,20,30,31,32,33); @weight = (19,18,17,16,15,14); for( (map{$_->[1]} sort{$b->[0] <=> $a->[0]} map{[$height[$_]*$weight[$_],$_]} (0..$#height))[0,1] ){ print "$_:$height[$_],$weight[$_]\n"; }

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://163939]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (2)
As of 2024-04-26 01:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found