"Exclusive or" Operator

suggest change

The operator for an “exclusive or” (for short XOR) is: ^

For bool operands, this operator returns true when exactly one side is true. For integral operands, ^ is bitwise exclusive or.

true ^ false   // Returns true
false ^ true   // Returns true
false ^ false  // Returns false
true ^ true    // Returns false

Feedback about page:

Feedback:
Optional: your email if you want me to get back to you:



Table Of Contents