Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: Problem with HOA.

by GrandFather (Sage)
on Aug 28, 2006 at 07:13 UTC ( #569940=note: print w/ replies, xml ) Need Help??


in reply to Problem with HOA.

Update wrong answer. cog has it right.

use strict; use warnings; my %hash=( 1=> [1.5, 2.1, 3.1], 2=> [1.2, 2.2, 3.2], 3=> [1.3, 2.3, 3.3], ); my @array = sort {$a<=> $b} map {@{$hash{$_}}} keys %hash; print "@array";

Prints:

1.2 1.3 1.5 2.1 2.2 2.3 3.1 3.2 3.3

DWIM is Perl's answer to Gödel


Comment on Re: Problem with HOA.
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (8)
As of 2015-07-03 02:39 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (47 votes), past polls