Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re: retrieving from a hash numerically

by Ido (Hermit)
on Jul 04, 2005 at 13:20 UTC ( [id://472228]=note: print w/replies, xml ) Need Help??


in reply to retrieving from a hash numerically

You could simply use:
for my $key (sort {$a<=>$b} keys %hash){ print $hash{$key} }
But, if you have a hash with keys 0..114, why won't you just use an array?

Replies are listed 'Best First'.
Re^2: retrieving from a hash numerically
by Anonymous Monk on Jul 04, 2005 at 13:31 UTC
    thanks ;-)

    this is exactly what i was after !

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (3)
As of 2024-03-28 17:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found