def dec.put
import bend-kit-tar@0.3.0.0/tar.bend as Tarimport Base
import bend-kit-bytes@0.3.3.0/bytes.bend as Bytes
575# n decimal digits of v ending at j, written back to front.
576def dec.put(n: Nat, a: Array<U32>, +j: U32, +v: U32) -> Array<U32>:
577 match n:
578 case 0n:
579 a
580 case 1n+p:
581 dec.put(p, Bytes.poke(a, j, (48 + (v % 10) : U32)), (j - 1 : U32), (v / 10 : U32))