def Decimal.show.point

bend-kit-bignum@0.1.0.0 · decimal.bend:214

import bend-kit-bignum@0.1.0.0/decimal.bend as Decimal
import Base

214# Digits with a point s places from the right, zero-padded to one whole digit.
215def Decimal.show.point(+s: Nat, +ds: String) -> String:
216  match s:
217    case 0n:
218      ds
219    case 1n+p:
220      Decimal.show.split(1n+p, String.append(
221        String.repeat("0", Nat.sub(2n+p, String.length(ds))), ds))

Uses (7)

Used by (1)