Typo - Type Your Program Once
by William Wilkinson"TYPO" is designed to help you find typing errors made when entering BASIC programs published in ANTIC. When used properly, TYPO will produce a table of values which can be used to pinpoint where an error was made. ANTIC will publish a table with every BASIC listing, and the user may compare the two tables to ensure they are identical. If they are not, then the user presumably made a "typo" which needs to be corrected.
How To Use TYPO
1. Enter program listing #1 EXACTLY as shown.2. LIST this program to disk ( LIST "D:TYPO.LIS" ) or cassette (via LIST "C:" ). When using a cassette, use an entire blank cassette for just this program.
3. Type NEW to clear memory.
4. Type in a program from the magazine.
5. LIST this program to the disk ( LIST "D:NAME" ) or cassette (LIST "C:" ). Type NEW and reenter the program ( ENTER "D:NAME" or ENTER "C:").
6. Append the TYPO program onto the end of the program from the disk (ENTER "D:TYPO.LIS" ) or cassette ( ENTER "C:" ).
7. Type GOTO 32000 and a checksum table will be printed on your screen. Compare this table with the one published, if they agree you are finished and the prograrh should run.
8. Note the value of the "Variable checksum" printed on the screen, and keep it handy.
9. If the table does not agree with the published table, examine the lines which have codes and/or lengths which disagree. Correct any errors.
10. IF AND ONLY IF the variable checksum you noted agrees with that printed in the magazine, goto step 7 above and try again.
11. If the variable checksums do NOT agree, you MUST goto step 5 above and perform the listing and reentering ritual! You may skip step 6, however, since presumably you have the combined programs now LISTed together.
Follow these instructions exactly!
What TYPO is Telling You
THIS PROGRAM IS FUSSY! It cares about every little period, comma, and even spaces. It also cares about the order in which you typed in program lines! The order in which the variable names are stored depends upon the order the lines were typed. Should this order be altered the values of the tokens and the subsequent checksums will be altered.The "Variable checksum" is used to correct for some of this by producing an (almost) unique checksum which depends on the order in which the variables are stored. If your checksum doesn't agree, you have either entered lines in the wrong order or misspelled a variable name. In either case, you MUST correct your error(s) and then go through the LIST / NEW / ENTER sequence to assure that the variables are put back in order.
The length shown is the number of bytes encountered by TYPo within the line number range shown. The two letter code is essentially a checksum of "length" bytes within that same range. If the length is correct and the checksum is off, you have made a spelling or punctuation error. Watch out: since all keywords and operators (including two character operators such as " =") are tokenized as one byte, the length might stay the same even though you type SETCOLOR for GLR. Note!! You MAY use abbrevations for keywords as long as the LlSTed result conforms to the magazine listing.
If the length bytes disagree you have added or deleted characters. If nothing obvious shows, pay special attention to characters in quoted strings and / or REMark statements. It is easy to omit a space or punctuation in a REMark, thinking that "REMarks don't matter"; but to TYPQ they do.