August 2012
Intermediate to advanced
976 pages
30h 17m
English
The AND (&), OR (|), and XOR (^) operators generate new values with the bit pattern composed from its two operands:
For each bit position in the result of the bitwise AND operator (the & operator) the bit is 1 if both operands contain 1; otherwise, the result is 0. For the OR (inclusive or) operator (the | operator), the bit is 1 if either or both operands contain 1; otherwise, the result is 0. For the XOR (exclusive or) operator (the ^ operator), the bit is 1 if either but not both operands contain 1; otherwise, the result is 0.
Warning
It is a common error to confuse the bitwise and logical operators (§ ...
Read now
Unlock full access