On Sat, Jun 20, 2009 at 00:58, Aruna Goke<mykl...@gmail.com> wrote:
> is negative index not allowed in perl6?
>
> i tried
>
> my @test = (1 .. 20);
> @test[-1].say;
>
> OUTPUT
> Use of uninitialized value
>

You have to say

@test[*-1].say;

now

http://perlcabal.org/syn/S09.html#Negative_and_differential_subscripts

-- 
Chas. Owens
wonkden.net
The most important skill a programmer can have is the ability to read.

Reply via email to