Python Unsigned Right Shift

Micah picture Micah · Jul 10, 2012 · Viewed 7k times · Source

Possible Duplicate:
How to get the logical right binary shift in python

How do I perform an unsigned right shift in python?

I.E. The java equivalent is this:

x >>> y or x >>>= y

Answer

MRAB picture MRAB · Jul 10, 2012

Integers in Java have a fixed number of bits, but those in Python don't, so an unsigned right shift would be meaningless in Python.