The program is listed below. The lines inside each pair of FOR and NEXT statements have been indented so that you can see how the program works; the spaces are not needed for the program to run.

1Qp WIDTH "LPTl:", 255

ll@ LPRINT CHR$(27);"A";CHR$(8); 12@ FOR R = 1 TO 6

138 LPRINT CHR$(27);"K";CHR$(l@);CHR$(@);

14a FOR X = 1 to 58

158LPRINTCHR$(17@);CHR$(85); 16P NEXT X: LPRINT

17@ NEXT R

lSp! LPRINT CHR$(27);"@"

If you run the program, you will see how it combines six print lines into a pattern.

There are five basic steps that the program goes through to produce this kind of pattern.

1.The computer is prevented from adding any extra characters by the WIDTH statement (line 100).

2.The line spacing is changed to 8/72 of an inch-the height of the dot patterns used in the program (line 110).

3.The program goes through the graphics commands the required number of times (lines 120 and 170).

4.A new graphics command is used for each line printed (lines 130-160). This part of the program is similar to the last example, but two columns are printed each time through the loop making a total of

100.

4-14

Using Software and Graphics