Handbook
Glossary
>digit ( n -- ch )
Vocabulary
math
.
parser
Inputs
n
an integer between 0 and 15
Outputs
ch
a character
Word description
Outputs a character representation of a digit.
Notes
This is one of the factors of
number>string
.
Definition
USING:
kernel
math
;
IN:
math.parser
:
>digit
( n -- ch )
dup
10
<
[
48
+
]
[
10
-
97
+
]
if
;
inline