alkis has asked for the wisdom of the Perl Monks concerning the following question:

hi i have a hash of hash like this $$name{'rel'} where $$name{'rel'} is a number.

i want to sort these numbers but the info i want is the names of the sorted numbers...

for ex:

name1=10

name3=8

name2=5

all the $name variables belong to @rel_file. how can i do it?

Replies are listed 'Best First'.
Re: sort hash ....
by Corion (Patriarch) on Jun 04, 2008 at 12:53 UTC

    This is a FAQ, which you find included with your Perl distribution and which is available online as well, for example by using a Google search with the keywords perl sort hash.

    Showing us some code would also have helped.