SPUG: Another stupid question, hash sorting
Peter Darley
pdarley at kinesis-cem.com
Tue Jul 2 18:09:00 CDT 2002
Friends,
I've got another stupid question that I'm hoping someone can answer for me.
I want to sort a hash on two values, and have been unsuccessful in my search
of the web for info on how to do it.
Specifically I have a hash containing {Score} and {Name} values, and I want
to primarily sort on score, and sort on name where the score is the same. I
can do this with a two step sort, but I figured that Perl was probably cool
enough to provide a simple way of tackling this.
Thanks,
Peter Darley
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
POST TO: spug-list at pm.org PROBLEMS: owner-spug-list at pm.org
Subscriptions; Email to majordomo at pm.org: ACTION LIST EMAIL
Replace ACTION by subscribe or unsubscribe, EMAIL by your Email-address
For daily traffic, use spug-list for LIST ; for weekly, spug-list-digest
Seattle Perl Users Group (SPUG) Home Page: http://seattleperl.org
More information about the spug-list
mailing list