Beefy Boxes and Bandwidth Generously Provided by pair Networks
laziness, impatience, and hubris
 
PerlMonks  

Re^3: Sorting Dates

by gjb (Vicar)
on Nov 24, 2005 at 11:11 UTC ( #511404=note: print w/replies, xml ) Need Help??


in reply to Re^2: Sorting Dates
in thread Sorting Dates

This doesn't sort the hash, it only converts the date from D/M/YYYY to YYYY/MM/DD so that it can be used as a key in your %datecount hash. This hash can be sorted the way you do it in your code fragment.

As to qw:

$ perldoc -f qw qw/STRING/ Generalized quotes. See "Regexp Quote-Like Operators" in perlop.
It returns a list of words without doing interpolation on them. It is just a convenient way of writing:
my @dates = ('5/7/2001' '3/10/2005' '1/1/1996' '2/1/1993');

Hope this helps, -gjb-

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://511404]
help
Chatterbox?
[ambrus]: MLX: if it's a work email, then it's probably not Uncle Sam that matters, but what the account managing server at work thinks your name is. Those can differ. For example, we've had two co-workers with identical real name at one point,
[ambrus]: so one got a stupid suffix in the email account (people have email address based on their real name here usually).

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (8)
As of 2017-01-19 14:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Do you watch meteor showers?




    Results (170 votes). Check out past polls.