Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: Range in Getopt

by toolic (Bishop)
on Oct 03, 2012 at 13:54 UTC ( #997063=note: print w/replies, xml ) Need Help??


in reply to Range in Getopt

Another way (stealing james2vegas's die message):
use warnings; use strict; use Getopt::Long; my $_debug = 1; # or whatever default you want it to be GetOptions('d=i' => \$_debug) or die("Invalid commmand line options.") +; die "Invalid Debug Level ($_debug)" if $_debug<1 or $_debug>4; print "\$_debug = $_debug\n";

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (4)
As of 2016-09-26 23:22 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Extraterrestrials haven't visited the Earth yet because:







    Results (493 votes). Check out past polls.