11 lines
174 B
Plaintext
11 lines
174 B
Plaintext
( returns negative value on error )
|
|
: _ ( c -- n )
|
|
( '0' is ASCII 48 )
|
|
48 -
|
|
DUP 0< ( bad ) OVER 2 < ( good ) OR IF EXIT THEN
|
|
( bad )
|
|
255 -
|
|
;
|
|
|
|
|