Perl 6 Perl 6 today #19

Arrays / Hashes

Unlike Perl 5, the sigil does not change for array or hash access:

my @suits      = ('Clubs', 'Diamonds', 'Hearts', 'Spades');
my %scores     = pmichaud => 52,
                 mäsak    => 95,
                 PerlJam  => 78;

say @suits[2];               # Hearts
say %scores{'pmichaud'};     # 52
Copyright © 2009
http://www.pmichaud.com/2009/pres/