def at
import ezx@1.11.0.0/src/share/args.bend as Argsimport Base
48# the nth argument, or "" when it was not given. Both the list and the count
49# are scrutinised together, so the walk needs no helper to branch through.
50def at(xs: List<&2, String>, index: Nat) -> String:
51 match xs index:
52 case Nil{} _m:
53 ""
54 case Con{h, _t} 0n:
55 h
56 case Con{_h, t} 1n+p:
57 at(t, p)