Newbie -- bitwise shifts

Irmen de Jong irmen at -NOSPAM-REMOVETHIS-xs4all.nl
Wed Feb 4 23:16:18 CET 2004


Batista, Facundo wrote:
> gerald.britton at allstream.com wrote:
> 
> #- 15 is binary 1111
> #- if I shift this left 2 bits I get 11
> 
> No.
> 
> If you shift 1111 left 2 positions, you get 111100.


He probably meant to shift it to the other left.

--Irmen



More information about the Python-list mailing list