# while2.py
from Processing import *
window(500, 500)

# Draw 1000 rectangles
i = 0
while True:
    i = i + 1
    if i >= 1000:
        break

    x = random(0, width())
    y = random(0, height())
    rect(x, y, 40, 40)
