kuroko/test/testLoopBreaks.krk

29 lines
539 B
Plaintext

let x = 1
while True:
x = x + 1
if x > 20:
break
if x > 15:
let y = 0
while True:
y = y + 1
print("[ y = ",y,"]")
if y == x:
break
print("y = ",y)
if x > 10:
print("not going to print this one :)")
continue
print("x = ",x)
print("hello",x)
for i in [1,2,3,4,5,6]:
if i == 2:
print("skipping 2")
continue
if i == 4:
print("4? ending early!")
break
print(i * 5)
print("Done")