0
break
When trying the following example in IDLE 3.6.0, I get an error message: i = 0 while 1==1: print(i) i = i + 1 if i >= 5: print("Breaking") break print("Finished") "SyntaxError: multiple statements found while compiling a single statement" WHat do I do wrong?
2 Answers
0
You copy:
"i=0
while True:
etc.
"
So you have a statement (i=0) followed by another (while True: etc.) and IDLE doesn't like that.
You can copy first "i=0" and then the rest of the code
0
Thanks.