Created
January 31, 2015 16:47
-
-
Save zeroeth/6d2b1995f1d3e1fbdf35 to your computer and use it in GitHub Desktop.
random cubes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
int square_top_x = 10; | |
int square_top_y = 20; | |
int square_bot_x = 100; | |
int square_bot_y = 200; | |
void setup() | |
{ | |
size(500, 500); | |
} | |
void draw() | |
{ | |
square_bot_x = int(random(width)); | |
square_bot_y = int(random(height)); | |
rect(square_top_x, square_top_y, square_bot_x, square_bot_y); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment