in reply to Sorting a Hash

Pass a function into sort that sorts on two criteria.

This kind of problem is directly addressed in a very large number of nodes (doing a SuperSearch for "search" might help) as well as in nearly every Perl book ever printed.

------
We are the carpenters and bricklayers of the Information Age.

Don't go borrowing trouble. For programmers, this means Worry only about what you need to implement.

Replies are listed 'Best First'.
Re: Re: Sorting a Hash
by jackdied (Monk) on Oct 19, 2001 at 01:54 UTC
    Also check out Schwartzian Transform, which is just the name given to using sort efficiently with complex data structures. Even if you don't use it for this project, you will sooner or later.

    -jackdied