Page 1 of 1

Order of && Operator

Posted: Mon Aug 02, 2004 2:47 am
by Vmusic
Hi,
Which order does PHP process the && operator?

if((a == "jo") && (b=="momma")){


what gets tested first??????????


Thanks!!!

Posted: Mon Aug 02, 2004 3:01 am
by markl999

Posted: Mon Aug 02, 2004 9:08 am
by Bill H
As a matter of readability, I use parentheses to specify order of operation even when operator precedence would do so for me. The issue is to make sure that when I read the code years from now I am clear on what I meant to happen.