我一直在用 python 编写一个简单的测验,但在我的 Python GUI 中不断收到“SyntaxError:在编译单个语句时发现多个语句”。请帮忙。
print("Welcome to my quiz!")
score = 0
question1 = str(input("What colour is a banana."))
if question.lower() == 'yellow':
print("Correct. The answer is", question1)
score = score + 1
else:
print("Incorrect. The answer is yellow, not", question1)
print score