def big.read
import yaml-for-bend@0.1.1.0/num.bend as Numimport Base
66# The digits of +s+ in +base+ (each a digit of that base) as a big number.
67def big.read(s: String, +base: Nat, acc: List<&2, Nat>) -> List<&2, Nat>:
68 match s:
69 case SNil{}:
70 acc
71 case SCon{c, t}:
72 big.read(t, base, big.mul.add(acc, base, digit(c)))