Perl 6 Cool Perl 6 #32

The .sort method

    %addrbook.classify({ .value.substr(0,1).uc }).sort

(
  "A" => ["allison\@parrot.org" => "Allison Randal", 
          "audreyt\@audreyt.org" => "Audrey Tang"], 
  "J" => ["jnthn\@jnthn.net" => "Jonathan Worthington",
          "jesse\@fsck.org" => "Jesse Vincent"],
  "L" => ["larry\@wall.org" => "Larry Wall"], 
  "P" => ["pmichaud\@pobox.com" => "Patrick R. Michaud"] 
)
Copyright © 2010
http://www.pmichaud.com/2010/pres/