Each model had two operating modes: Run and Prog.
Run In Run mode, the
command line could be openly used to execute one-line, non-BASIC operations. This is the normal mode used, from where arbitrary
calculations could be entered to receive results. The Run mode also allowed the
execution of the BASIC programs stored in the device. Instead of an "equals" key to initiate calculation evaluation, an "EXE" (execute) key was provided. This caused confusion with those who were used to traditional calculators. The = character was used only for variable
assignment, and evaluation tests in programs. The input of simple calculations would be aggregated on the command line, and no results would be displayed until the EXE key was pressed. In some models, a special ANS variable was provided to reuse the results of the previous calculation; in others, the previous calculation was automatically included if the next calculation began with an operator. Some valid calculation input examples (PC-8): SIN40 10+2+(8*1)/7 TAN (LOG (√(4/3)))
Prog The Prog mode changed the input from a command line to a program editor. In this mode, BASIC programs could be entered one line at a time. Up and down arrow buttons were provided to scroll up and down through the program space. On most models, free calculations could not be entered in the Prog mode. Certain models, especially the Casio-derived ones, called this mode
WRiTe mode. On the Sharp models, there was only one
line numbering space. In order for multiple programs to exist on the device, they had to be written in different ranges of line numbers. For example, it was common to insert one program starting with line 100, and another program starting at line 200, etc. Valid line numbers in most models were from 1 to 999. To prevent run-on execution, each program had to finish with the END command, unless run-on execution was desired. On Sharp-derived units, labels could be inserted into the program, usually single characters such that in Run mode, that program could be executed by depressing a special DEF key followed by the key of that character. This was equivalent to an explicit
GOTO command to the first line number of that section of program, which was also a valid way to execute programs from Run mode. In the Casio-derived models, the BASIC space was subdivided into segmented program spaces which could be numbered, cleared and executed manually, or could call each other. Many of the devices included a special
modifier key to expedite the entry of BASIC commands as well as scientific function names. The most common commands would each be associated with a key, and the full command could be entered by depressing the special modifier key, followed by the associated key for the command. In some models, BASIC and other commands would be converted into one-character tokens (converted to strings upon display) instead of being stored as whole strings. ==Memory==