计算一个整数中有多少个”1″
int count ( int i ) { int count = 0; while( i!=0 ) { i = i&(i-1); count++; }[......]
more…