B
This commit is contained in:
parent
e5e8880e41
commit
518da4a923
1019 changed files with 15877 additions and 0 deletions
8
Task/Bitwise-operations/Python/bitwise-operations-2.py
Normal file
8
Task/Bitwise-operations/Python/bitwise-operations-2.py
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
# 8-bit bounded shift:
|
||||
x = x << n & 0xff
|
||||
# ditto for 16 bit:
|
||||
x = x << n & 0xffff
|
||||
# ... and 32-bit:
|
||||
x = x << n & 0xffffffff
|
||||
# ... and 64-bit:
|
||||
x = x << n & 0xffffffffffffffff
|
||||
Loading…
Add table
Add a link
Reference in a new issue