std::numeric_limits<int>::max()
int count = 0; for (int xor = a ^ b; xor != 0; xor = xor & (xor-1)) { count++; }