0
Python switch文を試してみました。このループを働かせてください。毎回同じことを印刷するだけです。Python madlib whileループの問題
choice = input("Do you want to play a game? (y) or (n)")
while choice == "y":
while True:
print("1. Fun story")
print("2. Super Fun story")
print("3. Kinda Fun story")
print("4. Awesome Fun story")
print("5. Some Fun story")
choice2 = int(input("Which template of madlib would you like to play(Enter the number of your choice"))
if choice2 == 1:
noun1 = input("Enter a noun: ")
plural_noun = input("Enter a plural noun: ")
noun2 = input("Enter another noun: ")
print("Be kind to your {}-footed {}, or a duck may be somebody’s {}".format(noun1, plural_noun, noun2))
else:
print("Goodbye")
インデントを修正してください。 –