Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re: ARGV and online Perl commands

by toolic (Bishop)
on Jan 10, 2013 at 19:32 UTC ( #1012723=note: print w/replies, xml ) Need Help??


in reply to ARGV and online Perl commands

Here's what I get at my unix prompt:
perl -e "print $ARGV[1];" ONE- TWO- ARGV: Undefined variable.

But, if I change to single quotes to make my shell happy:

perl -e 'print $ARGV[1];' ONE- TWO- TWO-

UPDATE: when I switch my shell from tcsh to bash, I can duplicate your result.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1012723]
help
Chatterbox?
choroba has a small USB lamp
[ww]: ++ all (phony labels re "gaming"
[1nickt]: ambrus perhaps you know where the keys are?
[ww]: OTOH, -- for ads suggesting that being good at games is somehow eq "greatness"
[ambrus]: 1nickg: obviously the gamers don't know. but anyway, I need the whole room backlit, because watching a monitor in a dark room (like many people do) is tiring for my eyes, even more so than doing it in a lit room.

How do I use this? | Other CB clients
Other Users?
Others studying the Monastery: (18)
As of 2017-03-27 13:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Should Pluto Get Its Planethood Back?



    Results (320 votes). Check out past polls.