Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: Check For null Arguments

by AnomalousMonk (Abbot)
on Mar 13, 2013 at 16:25 UTC ( #1023251=note: print w/ replies, xml ) Need Help??


in reply to Check For null Arguments

Further to ramlight's post: One could also write something like this very early in the code:
    die "no command line arguments given" unless @ARGV;


Comment on Re: Check For null Arguments
Download Code
Replies are listed 'Best First'.
Re^2: Check For null Arguments
by rfleisch (Initiate) on Mar 13, 2013 at 17:44 UTC
    Thanks for these TWO tips. I have included them in my little perl script to have as a reference. Best regards to All -Ray

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1023251]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (18)
As of 2015-07-31 18:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (280 votes), past polls