{ $description "If " { $snippet "string" } " is a valid number literal, it is converted to a number, otherwise the current vocabulary search path is searched for a word named by the string." }
{ $errors "Throws an error if the token does not name a word, and does not parse as a number." }
{ $notes "This word is used to implement " { $link scan-word } "." } ;
HELP: parse-datum
-{ $values { "string" string } { "word/number" "a word or number" } }
+{ $values { "string" string } { "word/number" { $or word number } } }
{ $description "If " { $snippet "string" } " is a valid number literal, it is converted to a number, otherwise the current vocabulary search path is searched for a word named by the string." }
{ $errors "Throws an error if the token does not name a word, and does not parse as a number." }
{ $notes "This word is used to implement " { $link ?scan-datum } " and " { $link scan-datum } "." } ;
{ $description "Outputs a head sequence and the last element of " { $snippet "seq" } "; the head sequence consists of all elements of " { $snippet "seq" } " but the last Unlike " { $link unclip-last } ", this word does not make a copy of the input sequence, and runs in constant time." } ;
HELP: sum
-{ $values { "seq" "a sequence of numbers" } { "n" "a number" } }
+{ $values { "seq" "a sequence of numbers" } { "n" number } }
{ $description "Outputs the sum of all elements of " { $snippet "seq" } ". Outputs zero given an empty sequence." } ;
HELP: product
-{ $values { "seq" "a sequence of numbers" } { "n" "a number" } }
+{ $values { "seq" "a sequence of numbers" } { "n" number } }
{ $description "Outputs the product of all elements of " { $snippet "seq" } ". Outputs one given an empty sequence." } ;
HELP: infimum
-{ $values { "seq" "a sequence of real numbers" } { "n" "a number" } }
+{ $values { "seq" "a sequence of real numbers" } { "n" number } }
{ $description "Outputs the least element of " { $snippet "seq" } "." }
{ $errors "Throws an error if the sequence is empty." } ;
HELP: supremum
-{ $values { "seq" "a sequence of real numbers" } { "n" "a number" } }
+{ $values { "seq" "a sequence of real numbers" } { "n" number } }
{ $description "Outputs the greatest element of " { $snippet "seq" } "." }
{ $errors "Throws an error if the sequence is empty." } ;