Bitwise 'OR' operator ("|"): Will compare the bits of two numbers, and return a number with a 1 in every bit that has a 1 in either number. This is basically used to 'add' a bit to a number. Example: 0001 1010 | 0001 0101 = 0001 1111 Will compare the bits of two numbers, and return a number with a 1 in every bit that has a 1 in both numbers. This is used to see if a bit exists in a number. Example: 0001 1010 & 0000 1000 = 0000 1000 Will compare the bits of two numbers, and return a number with 1s where neither number has a 1. This is used to subtract a bit from a number.
Attributes | Values |
---|---|
rdfs:label |
|
rdfs:comment |
|
dcterms:subject | |
abstract |
|