langatator/examples/while_demo.ltor

14 lines
259 B
Text

# show case of 'continue' and 'break' keyword in their natural environment
set i to 0
while 1 do
if i > 10 then
break
end
if i = 5 then
set i to i+1
continue
end
print_number(i)
set i to i+1
end
print_number(i)