on 492ae2f help sign in
28 lines 412 B history raw
1### `++but`
3Binary digit
5Parse a single binary digit.
7Source
8------
10 ++ but (cook |=(a=@ (sub a '0')) (shim '0' '1')) :: binary digit
12Examples
13--------
15 ~zod/try=> (scan "0" but)
16 0
17 ~zod/try=> (scan "1" but)
18 1
19 ~zod/try=> (scan "01" but)
20 ! {1 2}
21 ! 'syntax-error'
22 ! exit
23 ~zod/try=> (scan "01" (star but))
24 ~[0 1]
28***