Perl 6 Perl 6 Lists and Arrays vivified #9

Operations on arrays

> my @words = < orange lime cherry banana lemon >;

We still have the functional form of many operations:

Display the number of elements

> say elems @words
5
> my $x = pop @words;

I generally prefer the method call form:

> say @words.elems
5
> my $x = @words.pop;
Copyright © 2012
http://www.pmichaud.com/2012/pres/