Skip to content

Instantly share code, notes, and snippets.

@jkwok91
Created April 18, 2014 04:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jkwok91/3ce30f587d0a4783f658 to your computer and use it in GitHub Desktop.
Save jkwok91/3ce30f587d0a4783f658 to your computer and use it in GitHub Desktop.
is this a fractal i still don't know
/*
fractal(?) 0
in which i use recursion to make things happen
april 17, 2014
*/
float w;
void setup() {
size(300,300);
background(0);
stroke(color(255,0,0));
noFill();
w = width-1;
noLoop();
}
void draw() {
if (w > 10) {
rect(0,0,w,w);
w = 3*w/4;
translate(w,w);
rotate(PI);
draw();
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment