SCREEN 12
CLS
VIEW (0, 0)-(639, 479)
WINDOW (-4, 0)-(6, 10)
RANDOMIZE TIMER
X = 0: Y = 0
COLOR 15
LOCATE 1, 1: PRINT "Fractal Fern"
LOCATE 2, 1: PRINT "from PC Magazine"
WHILE INKEY$ = ""
R = RND
IF (R <= .01) THEN
A = 0: B = 0: C = 0: D = .16: E = 0: F = 0
ELSEIF R > .01 AND R <= .86 THEN
A = .85: B = .04: C = -.04: D = .85: E = 0: F = 1.6
ELSEIF R > .86 AND R <= .93 THEN
A = .2: B = -.26: C = .23: D = .22: E = 0: F = 1.6
ELSE
A = -.15: B = .28: C = .26: D = .24: E = 0: F = .44
END IF
NEWX = (A * X) + (B * Y) + E
NEWY = (C * X) + (D * Y) + F
X = NEWX: Y = NEWY
PSET (X, Y), 2
WEND
SCREEN 0
END