Handbook
Glossary
parse-temperature ( str -- temp dew-point )
Vocabulary
metar
.
private
Inputs
str
an
object
Outputs
temp
an
object
dew-point
an
object
Definition
USING:
formatting
kernel
math
math.parser
sequences
splitting
;
IN:
metar.private
:
parse-temperature
( str -- temp dew-point )
"/"
split1
[
[
f
]
[
"M"
?head
[
string>number
]
[
[
neg
]
when
]
bi*
dup
C>F
"%d °C (%.1f °F)"
sprintf
]
if-empty
]
bi@
;