Home →C Programming Language →C Operators
C Logical Operators
Logical operators allow us to combine mutilple relational operators or logical operators into one boolean result. C programming language supports the negation (!), logical AND (&&), and logical OR (||). The order of precedence is !, &&, || . Here are the logic table of logical operators :
|
a |
b |
a&&b |
a||b |
!a |
|
True |
True |
True |
True |
False |
|
True |
False |
False |
True |
False |
|
False |
True |
False |
True |
True |
|
False |
False |
False |
False |
True |
