📅  最后修改于: 2022-03-11 14:48:34.155000             🧑  作者: Mango
shift = 0
while 1 > shift or 26 < shift:
try:
# Swap raw_input for input in Python 3.x
shift = int(raw_input("Please enter your shift (1 - 26) : "))
except ValueError:
# Remember, print is a function in 3.x
print "That wasn't an integer :("