juliosergio has asked for the wisdom of the Perl Monks concerning the following question:
I need to have access to individual elements of the ARGV array in an online Perl command. Apparently, I have come to getting the whole array as follows:
Thanks,
However, when I try to print just a single element, a weird output is what I get!$ perl -e "print @ARGV;" ONE- TWO- ONE-TWO-$
Is there something I'm missing?$ perl -e "print $ARGV[1];" ONE- TWO- ARRAY(0x92007ec)$
Thanks,
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: ARGV and online Perl commands
by toolic (Bishop) on Jan 10, 2013 at 19:32 UTC | |
Re: ARGV and online Perl commands
by blahblahblah (Priest) on Jan 10, 2013 at 20:07 UTC | |
Re: ARGV and online Perl commands
by 2teez (Vicar) on Jan 10, 2013 at 21:30 UTC | |
Re: ARGV and online Perl commands
by Anonymous Monk on Jan 11, 2013 at 02:42 UTC |
Back to
Seekers of Perl Wisdom