Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: Re: Re: Re: open failure code

by davido (Cardinal)
on Nov 27, 2003 at 05:47 UTC ( #310479=note: print w/replies, xml ) Need Help??


in reply to Re: Re: Re: open failure code
in thread open failure code

Of course the same could be done just with proper logical short circuit operators. Prefer the low-precedence ones for this sort of thing:

open FH, "<", $log and print "Success\n" or print "Failure\n";

That avoids trinaries and if/else's.


Dave


"If I had my life to live over again, I'd be a plumber." -- Albert Einstein

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (7)
As of 2021-03-07 12:57 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My favorite kind of desktop background is:











    Results (121 votes). Check out past polls.

    Notices?