OEGetBitCounts

OEGetBitCounts(a: OEBitVector, b: OEBitVector) -> (onlyA: int, onlyB: int, bothAB: int, neitherAB: int)

Count the number of bits when comparing the two OEBitVector arguments a and b. This function is optimized so that the bitvectors only need to be traversed once.

The counts are returned as the following arguments with the corresponding values.

*onlyA     =   a  & ~b;
*onlyB     =  ~a  &  b;
*bothAB    =   a  &  b;
*neitherAB = ~(a  &  b);

See also

These values correspond with the a, b, c, d values found on the Daylight theory page.