SECTION C FILE INTRO.C MODES OF OPERATION ****************** The BASIC system employs two distinct ways of working called DIRECT MODE and PROGRAM MODE . In DIRECT MODE commands are typed in from the keyboard and are processed when RETURN is pressed. In PROGRAM MODE the commands are taken from the program in memory and are executed in program sequence. DIRECT MODE may be subdivided into DIRECT COMMAND MODE, PROGRAM INPUT MODE and EDIT MODE. DIRECT COMMAND . Only one line is entered and does =================== not commence with a number. The line is typed in at the cursor and is executed by pressing RETURN. Up to 255 characters can be written in one line including all punctuation marks, symbols and spaces (A full 'line' in fact takes up about two and a half actual lines of text) Several separate commands can be put on one line separated by a colon, but on pressing RETURN the line will be executed and then forgotten. To execute the same command(s) again you would need to type the line afresh. The DIRECT COMMAND is more usually used for short command lines, maybe just one word. For example if a program was loaded, by typing RUN at the Ok prompt and then pressing RETURN the program would execute or 'run' . Other common single word commands are PRINT, LIST, LOAD and SAVE. PROGRAM INPUT This is the mode used to write programs. To ============= enter program input mode from direct command mode simply type a valid line number at the prompt. As soon as this first line number is typed you will be in program input mode. When you press [RETURN] at the end of the line, the line will not execute but simply be recorded in memory, and BASIC will wait for the next line. Alternatively if a program is loaded, using the command LIST at the cursor and pressing return will display the program in program input mode. You will have seen this when trying the short program earlier. EDIT MODE When typing in a command line, whether in PROGRAM INPUT ========= or DIRECT COMMAND mode the line can be altered or 'edited' until the RETURN key is pressed . This state is the EDIT MODE and can be recognised by the cursor on the line. Characters can be deleted or added at the cursor position until you are satisfied with the EDIT. When a program is in memory any line can be called up for editing by typing EDIT 100, where 100 is the line you want to edit.When complete press RETURN to set. At other times, such as when a syntax error is discovered by BASIC, the offending line will be presented for your attention in EDIT MODE, complete with cursor. Another way of entering EDIT MODE which can be extremely useful sometimes is by use of the AUTO command. but more of this later PROGRAM MODE When a program is loaded and you type RUN at the ============ cursor ( in DIRECT MODE) the program will execute or 'run' It can still accept input from the keyboard if the program is written so to do, as you will have seen in the program previously presented, where you were asked to make a choice by typing Y or N, pressing RETURN etc. When you begin to get used to BASIC you will find that all modes work together in a very natural way, and you will use the particular mode required without thinking about it too much. However it is as well to realise that there are these different ways in which BASIC works from the outset. BASIC programs in general are intended to be used solely in PROGRAM MODE but this course employs a different and novel principle. You are constantly invited to view the 'Works' so as to see what makes it tick and you will be using DIRECT MODE in it's various sub-modes quite a lot to do this and to skip about the program. You will be given clear instructions at all times to enable you to do this, but in a short time you will pick up the simple principles in the best possible way, by use. End of file INTRO.C time you will pick up the simple principles in the best possible