on 492ae2f help sign in
24 lines 346 B history raw
1### `++dit`
3Decimal digit
5Parse a single decimal digit.
7Source
8------
10 ++ dit (cook |=(a=@ (sub a '0')) (shim '0' '9')) :: decimal digit
12Examples
13--------
15 ~zod/try=> (scan "7" dit)
16 7
17 ~zod/try=> (scan "42" (star dit))
18 ~[4 2]
19 ~zod/try=> (scan "26000" (star dit))
20 ~[2 6 0 0 0]
24***