Pop the set bits! Watch them disappear one by one as we count.
n = n & (n - 1) removes the lowest set bit
O(number of set bits) - Most efficient!
Check each bit: (n >> i) & 1
O(log n) - Checks all bit positions
__builtin_popcount(n) or Integer.bitCount(n)
O(1) - Hardware instruction