On Thu, May 17, 2001 at 11:33:55AM +1000, King, Jason wrote:
> Peter Scott writes ..
> 
> >At 10:44 AM 5/17/01 +1000, King, Jason wrote:
> >>so here's the thing .. Perl doesn't have pointers .. only references
> >>.. so you can't have a 1500 element array and grab a reference to the
> >>700th element
> >
> >Oh yes you can:
> >
> >my @foo = qw(three blind mice);
> >my $elemref = \$foo[2];
> 
> yes .. sorry - I phrased that badly .. I meant that you couldn't grab a
> reference to an array starting at the 700th element

I've lost the thread of what is *actually* being attempted here, but...

perl -e '@x = (1..100);$q = [@x[50..$#x]];print "@$q\n"'

which gives you a reference to the values at least.

Of course, that's just evil.  If that's what you're trying to do, there
must be a better way to do it.  In fact, you should probably forget I
even brought this up.

MOVE ALONG, NOTHING TO SEE HERE!  :-)

dha

-- 
David H. Adler - <[EMAIL PROTECTED]> - http://www.panix.com/~dha/
"You can't give a 4 to truth." - Saul Williams

Reply via email to