array indexing, nested array literals

This commit is contained in:
2025-06-29 10:36:55 +02:00
parent 26598fe6f2
commit 574b9fd37c
6 changed files with 79 additions and 61 deletions

View File

@@ -1,10 +1,5 @@
func main[] : I64
let xs: Array = [5849, 3869, 2859]
Array.push(xs, 5242)
Array.push(xs, 6533)
Array.push(xs, 4574)
for i in 0..Array.size(xs)
xs
|> Array.nth(i)
|> print_i64()
let xs: Array = [[1, 2, 3], [4, 5, 6], [7, 8, 9]]
for x in 0..3
for y in 0..3
print_i64(xs[y][x])