ilo 0.11.3

ilo — a programming language for AI agents
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
-- lset xs i v: long-form alias for `lst xs i v` (list update by index).
-- The mset/lset symmetry mirrors mget/lget-style naming; canonical name is
-- still `lst` (3 toks vs 4) but `lset` is accepted so agents who reach for
-- it from the M↔L parallelism don't fall back to slice-rebuild patterns.
-- Resolved at the AST level; bytecode is identical to `lst` across engines.

hist samples:L n bins:L n>L n;@s samples{c=at bins s;bins=lset bins s +c 1};bins

-- run: hist [0,2,1,2,3,1,2,0] [0,0,0,0]
-- out: [2, 2, 3, 1]
-- run: hist [1,1,1] [0,0]
-- out: [0, 3]