Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re: Returned value from subroutine is 1 when returning ""

by mjscott2702 (Pilgrim)
on Jan 06, 2011 at 16:21 UTC ( #880855=note: print w/ replies, xml ) Need Help??


in reply to Returned value from subroutine is 1 when returning ""

You should use "or" instead of "||" here, since it has lower precedence - in fact, I believe(?) this is the recommended practice.


Comment on Re: Returned value from subroutine is 1 when returning ""
Re^2: Returned value from subroutine is 1 when returning ""
by DrHyde (Prior) on Jan 07, 2011 at 10:29 UTC
    I recommend not using 'or', 'and' etc, but instead using brackets to make precedence explicit.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others examining the Monastery: (11)
As of 2014-12-19 16:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (87 votes), past polls