diff options
Diffstat (limited to 'test.toc')
-rw-r--r-- | test.toc | 10 |
1 files changed, 7 insertions, 3 deletions
@@ -45,8 +45,10 @@ putf @= fn(x: float) { // }; g @= fn() int { - // foo : [10]int; // = new(int, 10); - // each _, i := foo { + foo : [10]int; // = new(int, 10); + total := 0; + each foo { total = total + 1; } +// each _, i := foo { // foo[i] = i; // }; // total := 0; @@ -55,7 +57,6 @@ g @= fn() int { // } // total - total := 0; each i := 1..10 { total = total + i; total @@ -71,4 +72,7 @@ main @= fn() { puti(g()); X @= g(); puti(X); + each i, j := 1..10 { + puti(i + j); + } }; |