home *** CD-ROM | disk | FTP | other *** search
/ Futura 17 / Futura_Issue_17_1995_NOSAUG_Disk_1_of_2_Side_A_BASIC.atr / flyer.doc < prev    next >
Text File  |  2023-02-26  |  4KB  |  1 lines

  1. ¢THE TURBO BASIC FLYER¢by Ron Fetzer, Ol' Hackers Atari User Group.¢¢¢A WORD ABOUT MYSELF¢¢    I have been working on the Atari 8-bit computer for many years.  I am a math and computer studies teacher in a JHS in Brooklyn N.Y.  When I went to College there were no courses in Computer Science so most of my computer knowledge I learned by myself.¢¢    In school we use Radio Shack TRS-80 Model 4 computers (yuk!) and also the APPLE IIE (double yuk!).  In these computers there is no such thing as copying in 1 pass per disk.  On the TRS-80 with 1 disk drive you switch disks about 15 times.  The APPLE IIE has 2 graphics modes and the sound is 1 channel.  Anybody who will use an APPLE IIE instead of an ATARI 130XE is INSANE.¢¢    I hope you will enjoy the FLYER.¢¢¢A WORD ABOUT THE TURBO BASIC FLYER¢¢    This flyer is published and written by me (mostly) for the enjoyment of and help in using TURBO BASIC.  It is intended for the beginning and intermediate Atari 8-bit user.  The programs will only work on Atari 8-bit computers.¢¢    The Turbo BASIC language is one of the easiest and most versatile languages written for the Atari 8-bit.  In addition it comes with a great compiler.  Turbo BASIC is available from many public domain sources for $2 to $3.  It is the bargain of the century!¢¢¢FINDING THE PARAMETERS OF NUMBERS¢¢    If you have a series of numbers, you can find the LOW, HIGH, AVERAGE and TOTAL of the series.  This technique is frequently used in programs dealing with business situations, grade averaging, science work, score keeping, etc.¢¢    In line 110 [PARAM.TUR is on Side B of this disk] we compare each element for the high number in the array.  In line 120 we compare each element for the low number in the array.  In line 130 we find the total of all the numbers.  In line 140 we find the average of the series of numbers.¢¢    We store the numbers in an array.  See the Turbo BASIC Programming Kit on arrays.  In this way we can manipulate the numbers easily.  The array has to be DIMed for the number of elements you expect to have.  In our example, the array is N(T).  We set the HIGH= to element 1.  We set the LOW= to element 1 in line 80.  This is so the comparison of the elements will always start with element 1.  You could have made line 80 outside the loop such as line 95.¢¢¢ENABLE SPACE BAR ONLY¢¢    Frequently you want a routine to disable all keys except the SPACE BAR.  This routine [SPACEBAR.TUR] can be used to restart scrolling by pressing the space bar.  It can also be used with documentation files and games.¢¢    Line 60 clears the key handler and tells it NO key was pressed.  Line 70 will become an infinite loop until 33 (the raw key code) for the space bar is pressed.  The program then goes to 80.¢¢¢SELECT THE NUMBER OF DECIMALS¢¢    You frequently do not want all decimal digits to be printed.  If you are using money you need only 2 decimals.  This program [DECIMALS.TUR] demonstrates how to print the number of decimals that you want.  When you multiply and divide by 10 you get 1 decimal.  When you multiply and divide by 100 you get 2 decimals, etc.¢¢¢GRAPHICS LOADER¢¢    This program [GRLOADER.TUR] will load an uncompressed graphics file (62 sectors) and show it in Graphics Mode 15.¢¢    In line 120 we use an infinite DO-LOOP so the graphic stays on the screen.  In Line 100 we put the graphics on the screen.  In Line 110 we get the colour information.¢¢¢¢Contact me at this address:  Ron Fetzer, 22 Monaco Avenue, Elmont, N.Y. 11003, USA.¢¢¢¢PARAM.TUR, SPACEBAR.TUR, DECIMALS.TUR and GRLOADER.TUR are included on Side B of this disk.  Load and run with Turbo BASIC.¢