Count the number of 1 bits (set bits) in a 32-bit unsigned integer. This is also called the Hamming weight.
With n = 00000000000000000000000000001011 (binary):
- 1 bits at positions 0, 1, and 3.
- Answer: .
With n = 11111111111111111111111111111101:
- 31 bits are set to 1.
- Answer: .
Constraints: Input is a 32-bit unsigned integer.