I have to show this program to my teacher in 10 days, but I’m stuck in the demo, I have to add a drawing later.
I tried to change the variables and I checked the indentations. if you can help me I will be happy if you share with me thank you and good bye.
print("your mission is finde treasure")
answerOne=input("left or right?")
if answerOne == "left":
answerTwo=input("swim or wait?")
if answerTwo == "wait":
answerTree=input("red,blue or yellow door?")
if answerTree == "yellow":
print("victory!")
else:
print("game over")
else:
print("game over")
else:
print("game over") ```
Post your code into the question. Obviously indentation is important to this question, and that’s unreadable in a comment.
♦
See: I’m getting an IndentationError (or a TabError). How do I fix it?
The two indented
if
statements need to be on the same indentation level as the previous line. Basically, only increase indentation after lines which end with a colon: