0
此代碼適用於我正在編寫的基本冒險遊戲。即使我在Python中輸入'拒絕'或'sdef',我也會死去('你變成了工作狂等等')。基本If語句無法正常工作 - Python
幫助!!
from sys import exit
def dead(why):
print why
exit(0)
def nyc():
print '''You arrive in NYC and have a bank job lined up. will you take it or leave it?'''
choice = raw_input('> ')
if 'take' or 'accept' in choice:
dead('You become a workaholic and die of heart failure.')
elif 'refuse' or 'decline' or 'leave' or 'not' in choice:
bum()
else:
dead('Its banking or no deal buddy...you dead')