sd:star_forth_dictionary
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revision | |||
| sd:star_forth_dictionary [2026/03/14 10:27] – appledog | sd:star_forth_dictionary [2026/03/14 11:49] (current) – appledog | ||
|---|---|---|---|
| Line 3: | Line 3: | ||
| Here is a list of each word that comes standard in Star Forth. Included is a short definition as to its general usage. | Here is a list of each word that comes standard in Star Forth. Included is a short definition as to its general usage. | ||
| - | = BYE | + | == + (add) |
| + | This adds the two numbers on the top of the stack and pushes the result. | ||
| + | |||
| + | 1 2 + . | ||
| + | |||
| + | This puts a 1 and a 2 on the stack, then adds them and pushes the result. Then, the . (dot) command prints the result, which is 3: | ||
| + | |||
| + | 3 ok | ||
| + | |||
| + | == BYE | ||
| This quits the REPL (the Forth environment). | This quits the REPL (the Forth environment). | ||
| Line 15: | Line 24: | ||
| 5 . ( this prints 5. ) | 5 . ( this prints 5. ) | ||
| 1 1 + . ( this prints 2. ) | 1 1 + . ( this prints 2. ) | ||
| + | |||
| + | == .N (dotn) | ||
| + | This is the print command, like . (dot) but it does not print a space after numbers. | ||
| ----- | ----- | ||
| //More coming soon!// | //More coming soon!// | ||
sd/star_forth_dictionary.1773484028.txt.gz · Last modified: by appledog
