def digits.go
import ezmcp@0.1.0.0/src/rpc.bend as Rpcimport Base
51# whether every char of a text is an ASCII digit (true for the empty text)
52def digits.go(text: String) -> Bool:
53 match text:
54 case SNil{}:
55 True{}
56 case SCon{head, tail}:
57 digits.and(Char.is_digit(head), _u => digits.go(tail))