-3
however = ["In converse","On the other hand"]
furthermore = ["To add insult to injury","To add fuel to fire",]
conclusion = ["To ram the point home","In a nutshell"]
def prompt():
answer = str(input("Type either 'however','furthermore' or 'conclusion': "))
return answer
reply()
def reply():
if answer == "however":
print(however)
elif answer == "furthermore":
print(furthermore)
elif answer == "conclusion":
print(conclusion)
else:
prompt()
prompt()
prompt()
何が起こっているのですか?それだけでdoesntの印刷私はあなたが答え私はこの単純なpythonスクリプトを実行することができません
を返すことによってプロンプト()関数を終了するので、呼び出されません全て
関数呼び出しの 'reply()'はreturn文の後にあります。それは問題です。 –
関数、パラメータ、引数、スコープ、実行順序などの詳細な調査を行う必要があります。 – TigerhawkT3