real


Vocabulary
math

Class description
The class of real numbers, which is a disjoint union of rationals and floats.

Definition


Methods
































































M: real elapsed-time
dup 0 < [ "negative seconds" throw ] when [
{
{ 60 "s" }
{ 60 "m" }
{ 24 "h" }
{ 7 "d" }
{ 52 "w" }
{ f "y" }
} [
[ first [ /mod ] [ dup ] if* ] [ second ] bi
swap dup 0 >
[ number>string prepend , ] [ 2drop ] if
] each drop
] { } make [ "0s" ] [ reverse " " join ] if-empty ;