On Aug 8, 11:05 pm, [EMAIL PROTECTED] (John W. Krahn) wrote:
> > Subject: slices
>
> Your examples are not using slices.  A slice implies a list (more than one) of
> indexes

No "more than one" required.  A 1 element list is a list.

@bar[0,1] = `$cmd`;
assigns the first two lines of $cmd's output to the first two elements
of @bar.
@bar[0] = `$cmd`;
assigns the first line of $cmd's output to the first element of @bar.
$bar[0] = `$cmd`;
assigns all of the $cmd's output to the first element of @bar.

Paul Lalli


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to