Skip to content

bitxor

Bitwise XOR of two integers.

v = bitxor(a, b)

Returns the integer whose bits are set where exactly one of a and b has a set bit.

bitxor(12, 10) % 6 (1100 ^ 1010 = 0110)
  • bitand — Bitwise AND of two integers.
  • bitor — Bitwise OR of two integers.