Baidu Experience | Baidu Know | Baidu Home | Login | Registered
- News
- Web page
- Stick
- Know
- Experience
- Music
- Image
- Video
- Map
- Encyclopedia
- Library
- Home
- Classification
- Magazine
- Task
- Sign
- Back to enjoy program
- Mall
- Know
Baidu Experience > Maternity/Education > Education > Vocational Education logical Operators for PHP basic syntax
- |
- Browse:671
- |
- Updated: 2014-05-20 15:02
Step through Reading
Logical operators are logical and logical or logical, logical, OR
Method/Step
- 1
And or && logic and
Returns true if both sides of operands are true, otherwise false is returned
Example $a and $b
$a && $b
- 2
OR OR | | Logical OR
Returns False if both operands are false, otherwise true
Example $a or $b
$a | | $b
- 3
Not OR! Logical Non-
Returns False if the operand is true, otherwise true
Example not $b
! $b
- 4
XOR Logic XOR
Returns True when both operations have only one true, otherwise false is returned
Example $a XOR $b
END
experience content is for reference only, if you need to solve specific problems (especially in the areas of law, medicine, etc.), we recommend that you consult the relevant professionals in detail. Report
Author's statement: This experience is based on the actual experience of the original, without permission, declined reproduced. vote (1) few (0) I have questions (0) Exchange of relevant experience
- PHP basic Syntax bitwise operator 12014.05.21
- PHP BASIC Syntax structure 02013.11.24
- Other operators of PHP basic syntax 02014.05.21
- PHP basic syntax expressions and operator precedence 02014.05.22
- C Language Programming Logical operator Calculator method 02012.11.17
Related tagsToday spending meta-writing experience Rich >>yywch1 author experience
- Multi-directional conditional branching structure of PHP Process Control
- PHP Process Control One-way branch and two-way branch knot ...
- PHP basic syntax expressions and operator precedence
- Other operators of PHP basic syntax
- PHP basic Syntax bitwise operator
••If you want to complain, please go to Baidu Experience Complaint Center, if you want to put forward comments, suggestions, please go to Baidu Experience Management bar feedback. Popular magazines
- 1th Issue writing skills 543 times share
- 12th Issue I wish you a "pregnant"281 times share
- 1th Issue when we have children 186 times share
- 1th Issue New Term 78 times share
- 1th Issue dietary guidance for pregnant women 388 Share
2©2015baidu use Baidu before must read Baidu experience agreement author creation Works agreement
Logical operator of PHP basic syntax