好吧所以。。。在
print("What do you wanna do?")
input1 = input()
if input1 == "Stab this guy" or input1 == "stab this guy":
print("You stabbed that guy and killed him.")
elif input1 == "Punch this guy" or input1 == "punch this guy":
print("You punched him...")
我想用这些复杂的输入创建一个循环,所以当你输入一个仍然复杂但没有被提及的输入时,我希望它打印出类似“对不起,没有抓住那个”这样的内容,这样他们就必须重复输入列表中包含的另一个输入,直到他们说出正确的输入为止。在
在已有的基础上:
编辑:
要同时处理关键字,这是一个想法:
^{pr2}$相关问题 更多 >
编程相关推荐