> On 16 Jun 2017, at 06:23, Gabor Szabo <szab...@gmail.com> wrote: > > On Sat, Jun 10, 2017 at 9:38 AM, Brent Laabs <bsla...@gmail.com> wrote: >> I thought: >> $ is Scalar >> @ is Array >> % is Hash >> & is a function >> > > Reading this https://docs.perl6.org/language/containers I just found > out that a @-variable can also contain a List, > not just an array: > >> my @z = () > [] >> @z.^name > Array >> my @z := () > () >> @z.^name > List
You can bind *anything* that does Positional to an @-variable: $ perl6 To exit type 'exit' or '^D' > my @a := 42 but Positional 42 > @a[0] 42 > @a[1] Index out of range. Is: 1, should be in 0..0 in block <unit> at <unknown file> line 1 Liz