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

Re: Re: Re: "Correct" program style questions

by Anonymous Monk
on Oct 23, 2002 at 19:08 UTC ( #207497=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    use locale;
    
    my $color = param('color') =~ /^\w+$/ ?
                param('color') :
                "default color";
    
  2. or download this
    my $color = "default color";
    $color = param('color') if param('color') =~ /^\w+$/;
    
  3. or download this
    use locale;
    
    ...
    }
    
    my $color = is_alpha(param('color')) || "default value";
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://207497]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (4)
As of 2017-02-22 07:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    Before electricity was invented, what was the Electric Eel called?






    Results (325 votes). Check out past polls.