diff options
Diffstat (limited to 'examples/10.src')
| -rw-r--r-- | examples/10.src | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/examples/10.src b/examples/10.src index 0ec38ea..59f91e1 100644 --- a/examples/10.src +++ b/examples/10.src @@ -1,14 +1,16 @@ let main = () => i64 { let counter = 0; - while !(counter == 10) { + while counter < 10 { print(counter); counter = counter + 1; }; - while counter == 0 { - print(0); + while true { + if counter == 10 { + return counter; + }; }; - return counter; + return 1; }; |