You're missing a few : after your IF statements. Also, you can't have an IF or ELIF statement with nothing following it:
name = input("Type your name")
print("Welcome", name, "to this adventure!")
answer = input ("You wake up, and are laying on a bed.(get up/stay asleep")
if answer == "get up":
print('You have to put stuff after an IF statement - It cannot be blank')
elif answer == "stay asleep":
print('You have to put stuff after an IF statement - It cannot be blank')
else:
print("You stayed asleep and had no adventure, and lost.")
What error did i make?(begginer error)
This is my code so far:
name = input("Type your name")
print("Welcome", name, "to this adventure!")
answer = input ("You wake up, and are laying on a bed.(get up/stay asleep")
if answer == "get up"
elif answer == "stay asleep"
else:
print("You stayed asleep and had no adventure, and lost.")
It said the “get up” was a syntax error, what did i do wrong?
You're missing a few
:
after yourIF
statements. Also, you can't have anIF
orELIF
statement with nothing following it: