运行 ❯
获取
自己的 Python
服务器
×
更改显示方向
更改主题,深色/浅色
前往 Spaces
print(3 << 2) """ The << operator inserts the specified number of 0's (in this case 2) from the right and let the same amount of leftmost bits fall off: If you push 00 in from the left: 3 = 0000000000000011 becomes 12 = 0000000000001100 Decimal numbers and their binary values: 0 = 0000000000000000 1 = 0000000000000001 2 = 0000000000000010 3 = 0000000000000011 4 = 0000000000000100 5 = 0000000000000101 6 = 0000000000000110 7 = 0000000000000111 8 = 0000000000001000 9 = 0000000000001001 10 = 0000000000001010 11 = 0000000000001011 12 = 0000000000001100 """
12