> David Storrs wrote:
> > 
> > Thinking about it, I'd rather see lvalue slices become a nicer version
> > of C<splice()>.
> > 
> >      my @start = (0..5);
> >      my @a = @start;
> > 
> >      @a[1..3] = qw/ a b c d e /;
> >      print @a;   #  0 a b c d e 4 5
> 
> What would happen if I used 1,2,3 instead of 1..3?  Would it do the same
> thing? 

Of course.

> I wanna know what happens if I do:
> 
>        @a[0,2,4] = qw/ a b c d e /;

It would probably do the same as in Perl 5; the same thing as:

    @a[0,2,4] = << a b c >>;

(those << >> brackets are new shorthand for qw, not that qw is going
anywhere)

Luke

> -- 
> $a=24;split//,240513;s/\B/ => /for@@=qw(ac ab bc ba cb ca
> );{push(@b,$a),($a-=6)^=1 for 2..$a/6x--$|;print "[EMAIL PROTECTED]
> ]\n";((6<=($a-=6))?$a+=$_[$a%6]-$a%6:($a=pop @b))&&redo;}

Reply via email to