Because...
Decimal Binary 123 01111011 4 00000100 ======== 00000000 when ANDed together
The answer comes from ANDing the bits in the columns together. Bit 2 (third from the right) has a decimal value of 4 (because 22 = 4).
Is that any clearer?
In reply to Re^3: Bitwise and operator question
by FunkyMonk
in thread Bitwise and operator question
by Severy
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |