The : (colon) and ";" (semicolon) are used when defining forth words (word in this case is not the same as the term word defined in Table 5-1 ). To start a Forth word definition use the colon <:> symbol, to end a word definition, use the <;> semicolon. Here is an example of a word definition:
: HI ." Hello New World";
The example also uses the word ." (dot quote) within the HI colon definintion. The word ." (dot quote) tells the interpreter to collect the characters that follow it until reaching a closing " (quote) character. Words are often combinations of other words that provide the functions needed to accomplish the required result. In this case, the definition of the HI specifies that the interpreter is to collect the text, Hello New World. If you enter the above definition, press the Return key, and then type HI and press the Return key again, the characters Hello New World followed by the prompt are displayed.
The following section lists, and briefly defines, commonly used Forth commands.