Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Two simple code style advice questions (tye)

by tye (Cardinal)
on Jan 18, 2013 at 04:56 UTC ( #1013951=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    my %ntests;  $ntests{$_} = 0 for @tests;
    
  2. or download this
    @{ \my %ntests }{ @tests } = (0)x@tests; # :)
    
  3. or download this
    my $mol = '';
    $mol = 'forty two'
        if  42 == $n;
    
  4. or download this
    my $mol =
        ! defined $n
    ...
        42 == $n
            ? 'forty two'
            : '';
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (16)
As of 2014-09-18 18:56 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (121 votes), past polls