[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Two-liner; Circles
Whoops! I just saw a notice about the two-liners contest so I decided to
fire up the ol' brain pan and knock out a few fun ones. This is the first
of a couple of hacks with my favorite graphic subject; fun with circles.
The fun part of getting this was to fit in two lines was setting up a flag
to toggle the color between black and white. I had to tweek the margins a
bit to get this to post right so I hope it transfers okay.
0 REM 'CIRCLES' A TWO-LINER BY JOHN L. GRAHAM. PRESS CONTROL-C TO STOP.
1 A = 8 * ATN (1):B = 100:C = A / B:D = 140:E = 96:F = 0: HGR2
2 F = F + 1:G = (F - 2 * INT (F / 2)) * 3: HCOLOR= G:H = 80: FOR I = 0
TO H STEP 20: FOR J = 0 TO A STEP C:K = D + H * COS (J):L = E + I *SIN
(J): HPLOT K,L: NEXT : NEXT :I = H: FOR H = I - 20 TO 0 STEP - 20:FOR
J = 0 TO A STEP C:K = D + H * COS (J):L = E + I * SIN (J): HPLOT K,L:
NEXT : NEXT : GOTO 2
Have fun!
John