Archives of Genesis8 Amstrad Page

Mandelbrot in one line of basic by Demoniak


Just copy this one line of basic code by Demoniak and paste it in WinApe in the File Menu (or Ctrl + F11, or with any other Amstrad CPC emulator. Just for fun, like the Nyan Cat.

10 MODE 0:e=-1.3:FOR y%=0 TO 199:d=-2.4:FOR x%=0 TO 159:z=0:i=0:a%=0:WHILE a%<15 AND (z*z+i*i)<4:s=(z*z)-(i*i)+d:r=(2*i*z)+e:z=s:i=r:a%=a%+1:WEND:PLOT x%*4,y%*2,a%:d=d+0.0215:NEXT:e=e+0.013:NEXT

P.S. : in the general settings of WinApe, click on display every 1 frame and Turbo Mode, or you may have to wait a bit...

P.P.S : the second image is another basic source (more than 1 line) by Tronic-GPA.

Mandelbrot en une ligne de basic par Demoniak  Mandelbrot NOT one liner by Tronic-GPA

For more news, Go to home page