>>>for i in [12, 16, 17, 24, 26] ... if i % 2 == 1: ... break ... print(i) ...print("done") #you can not do this, because you can not use syntax or etc. at the end of loop #you have to close the loop by pressing enter at the end and then type the rest of code #like this: >>>for i in [12, 16, 17, 24, 26] ... if i % 2 == 1: ... break ... print(i) ... >>>print("done")
here's the result:
>>>for i in [12, 16, 17, 24, 26] ... if i % 2 == 1: ... break ... print(i) ... 12 16 >>>print("done") done