Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Writing portable code

by rovf (Priest)
on Mar 08, 2013 at 09:29 UTC ( #1022361=perlquestion: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    sub f {
      if($^O =~ /Win/) { .... } else { ... }
    }
    
  2. or download this
    my $f = if($^O =~ /Win/) ? sub { ... } else { ... };
    
  3. or download this
    # Not real Perl code right now!
    IF ....
    ...
      sub f{ ... }
      sub g { ... }
    END
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://1022361]
Approved by marto
Front-paged by Lotus1
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (11)
As of 2016-06-26 11:18 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My preferred method of making French fries (chips) is in a ...











    Results (328 votes). Check out past polls.