from turtle import *
import random

colors = ["#1CA195", "#277B72", "#277B61", "#AE5B28"]
colors_2 = ["#e63946", "#f1faee", "#a8dadc", "#457b9d", "#1d3557"]
colors_3 = ["#141115","#4c2b36","#8d6346","#ddf45b","#c6f91f"]

pensize(3)
speed(0)
tracer(0,0)

rand_cols = []

for i in range(36):
    rand_cols.append(random.choice(colors))

penup()
for j in range(1000):
    print(j)
    for i in range(36):
        fd(50)
        lt(50)
        pendown()
        color(rand_cols[i])
        begin_fill()
        for i in range(3):
           fd(100)
           lt(120)
        end_fill()
        penup()
        rt(50)
        bk(50)
        lt(10)
    lt(1)
    update()
    clear()

"""
for i in range(72):
    fd(150)
    dot(20 + random.randrange(30), random.choice(colors_2))
    bk(150)
    lt(5)

for i in range(72):
    side_len = random.randrange(10 + random.randrange(15))
    fd(200)
    rt(45)
    pendown()
    color(random.choice(colors_3))
    begin_fill()
    for i in range(4):
        fd(side_len)
        lt(90)
    end_fill()
    lt(45)
    penup()
    bk(200)
    lt(5)

"""

hideturtle()

#dot(size=None, *color)

done()
