def fill
import bend-kit-bits@0.1.0.1/bits.bend as Bitsimport Base
226def fill(f: Nat, t: Array<U32>, +i: U32, +step: U32, +e: U32) -> Array<U32>:
227 match f:
228 case 0n:
229 t
230 case 1n+p:
231 fill(p, Array.set(U32, t, i, e), (i + step : U32), step, e)