Getting at the bits of a 32-bit integer

Peter Hansen peter at
Tue Aug 24 07:00:07 CEST 2004

Grant Edwards wrote:

>>If you're new to Python and you are twiddling bits, the odds
>>favor the new user falsely importing old paradigms from other
> Probably so.

Especially as the OP didn't say he was trying to break apart
Ethernet headers, serial data streams, or suchlike.  He just
seems to want to grab a few bits for his own purposes, and
like Jeremy I doubt that the need is real (though also like
he I admit the possibility it could be!) and am quite curious
to hear from the OP again...


More information about the Python-list mailing list