in reply to Re: counting set bits in binary file
in thread counting set bits in binary file
That doesn't work:
>perl -le "print(unpack('%32b*', 0x13))" 7
There are 3 bits set in 0x13, not 7.
Sorry, my mistake.
>perl -le "print(unpack('%32b*', chr(0x13)))" 3
|
|---|