Perl 6 screencast - part 2 - arrays

This article is about Perl 6. If you are looking for solution regarding the current production version of Perl 5, please check out the Perl tutorial.


Direct link to the Perl 6 arrays screencast

See more Perl 6 entries.

Perl 6 Code examples


  use v6;
  my @names = "Foo", "Bar", "Moo";
  say @names[];
  say "Hello {@names} how are you?";
  say "Hello { join('; ', @names) } how are you?";


  use v6;
  my @names = ;
  say "Hello {@names} how are you?";
  for @names -> $n {
    say $n;
  }


blog comments powered by Disqus

Did you like this article?

Get notified when I publish new content!