Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Optional Arguments..?

by davido (Cardinal)
on Jun 03, 2012 at 03:16 UTC ( [id://974085]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    if( defined $ARGV[2] ) {
        # Handle the search string.
    ...
        # Perform whatever default preparations are necessary in
        # the absence of a defined search string.
    }
    
  2. or download this
    $ARGV[2] //= 'Default value';
    
  3. or download this
    my $pattern = $ARGV[2] // 'Default value';
    

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (7)
As of 2024-03-28 11:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found