Team-Fly
Previous Section Next Section

B.8 Bitwise Operations: Friend Functions

const LINT
operator ^ (const LINT& a,
     const LINT& b);

XOR, c = a ^ b;

const LINT
operator | (const LINT& a,
     const LINT& b);

OR, c = a | b;

const LINT
operator & (const LINT& a,
     const LINT& b); 

AND, c = a & b;

const LINT
operator << (const LINT& a,
     const int i);

left shift, b = a << i;

const LINT
     const int i);

right shift, b = a >> i;

const LINT
shift (const LINT& a,
     const int i);

shift (left and right) by i bit positions, b = shift (a, i);


Team-Fly Previous Section Next Section