004 grid dimensioned write and count

✓ Passing This code compiles and runs correctly.

Code

input.k

Actual

2

Expected output

✓ Zig✓ JavaScript
2

Flows

flow ~new click a branch to expand · @labels scroll to their anchor
new (expr: cells, dimensions: 3x3, source: v: 0[i64])
flow ~new click a branch to expand · @labels scroll to their anchor
new (expr: acc, source: n: 0[i64])
flow ~stored click a branch to expand · @labels scroll to their anchor
stored (source: cells[0, 0].v: 1)
flow ~stored click a branch to expand · @labels scroll to their anchor
stored (source: cells[2, 1].v: 1)
flow ~sweep click a branch to expand · @labels scroll to their anchor
sweep (expr: cells)
flow ~print.ln click a branch to expand · @labels scroll to their anchor
print.ln (expr: "{{ acc.n:d }}")

Test Configuration

MUST_RUN