2022-04-10 15:55:56 +02:00

23 lines
435 B
Plaintext

// This program is a simple test of while loops, counting down from 19 to 0
// and skipping 10 (if continue is implemented)
func while_test ()
begin
var a
a := 20
print a
if a > 0 then print "foobar"
while a > 0 do
begin
if a = 10 then
begin
a -= 1
print "Skip..."
continue
end
else
a -= 1
print a
end
return 0
end