0
Syntax issue
>>> i=0 >>> while True: i=i+1 if i==2: print("Skipping 2") continue if i==5: print("Breaking") break print(i) print("Finished") 1 Finished Skipping 2 3 Finished 4 Finished Breaking >>> Why does print(i) have to be positioned where it is?
1 Answer
+ 3
because Python doesn't use brackets to determine blocks of code, but uses whitespace instead.