Categories
Uncategorized

Count the bits in a 32 bit integer

Give a very good method to count the number of ones in a 32 bit number. (caution: looping through testing each bit is not a solution). (Got this question from http://www1.cs.columbia.edu/~kns10/interview/ )

Leave a Reply