Bitwise

From RevaWiki

Jump to: navigation, search

Glossary entry


A "bitwise" operator does its operation on each bit of both inputs. For example, if the inputs are "2" and "3", then:

2 3 and    | gives 2:  0010 and 0011 --> 0010
2 3 or     | gives 3:  0010 or  0011 --> 0011
2 3 xor    | gives 1:  0010 xor 0011 --> 0001

A related concept is boolean operators

Personal tools