私は学校のプロジェクトのクイズゲームを作成しています。ユーザーが無効なコマンドを入力すると、戻って入力を再試行してそのメニューに戻り、まったく同じ入力ボックスを表示してコードを試行するようにしたいと思います。また。これを実現したい部分を投稿します。
#---->TO HERE
if userinput == str("help"):
print ("This is the help menu")
print ("This is how you play")
else:
print ("Invalid Command")
#This is where I want the user to go back and try entering a command again to get the same code to run through again.
#FROM HERE <----