GRAPH-PLOTTER (16K ZX-81)
by Wilton J Faberge
from ZX Computing 2 (August-September 1982), page 47

Many dialects of BASIC include an ELSE option, used in the statement
IF...THEN... ELSE. There is no such function in zx BASIC, but the computer's
logic can be used to emulate this. Wilton J. Faberge shows you how.

The IF...THEN...ELSE is a very useful variation on IF. The computer can be
programmed to do something if the condition being tested for is found to be
true, and something else, other than just go to the next line, if the condition
is found to be false.

You can use the following substitution for IF...THEN... ELSE to produce some
very interesting graphs. You simply enter the function you would tike graphed
in line 55. This is not the most efficient method of programming on the ZX
computers, but it is useful as a means of demonstrating the IF...THEN...ELSE
substitution.

As the program runs, it evaluates K each time it comes to line 55. Line 70
looks at the value of K and prints a zero if K is greater than or equal to
point five, and a full stop if K is less than point five. This is the same as a
line reading IF K is greater than or equal to point five print "0" ELSE print
".".

Each of the other graphs uses different values for K, as generated by line 55.
The condition tested for in line 70 also varies. Run the samples given, using
your own choice of graphics symbol in line 70, and then create a few of your
own. It is likely that you'll have to change the scaling for certain functions.
