Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: Re: Re: Conditional style (if, &&) query

by blakem (Monsignor)
on Oct 17, 2001 at 03:21 UTC ( [id://119286]=note: print w/replies, xml ) Need Help??


in reply to Re: Re: Conditional style (if, &&) query
in thread Conditional style (if, &&) query

Your last bit of code confused me....
return 1 && $a && $b;
is identical to
return $a && $b;
is identical to
return 1 && 1 && 1 && $a && $b
So I don't follow your last paragraph...

Update
Were you perhaps thinking of:

return $a && $b && 1;
which will "coerce" all TRUE responses to be 1 instead of the value of $b?

-Blake

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (6)
As of 2024-04-25 15:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found