Pookkalam by Gayatri

Code

def random_color():
    r = random(255)
    g = random(255)
    b = random(255)
    return color(r=r, g=g, b=b)
shape = rectangle(w=60, h=60,stroke=random_color())| repeat(9, rotate(10))
c = circle(r=2,y=45,fill=random_color(),stroke=random_color())| repeat(36, rotate(10))
e = ellipse(w=20,h=50,stroke="red")+ellipse(w=20,h=50,y=75,stroke=random_color())|repeat(36,rotate(10))
c1 = circle(r=5,fill=random_color(),stroke=random_color(),y=95)+circle(r=4,fill=random_color(),stroke=random_color(),y=55)|repeat(36,rotate(10))
s = rectangle(w=200,h=200,stroke=random_color())|repeat(36,rotate(10))
c2 = circle(r=5,fill=random_color(),stroke=random_color(),y=140)+ellipse(w=10,h=20,y=156,fill=random_color(),stroke=random_color())|repeat(36,rotate(10))
r = rectangle(w=300,h=300,x=0,y=0,fill="white")
show(r,shape,c,e,c1,s,c2)
bud = circle(r=20,fill=random_color())
petal1 = circle(y=60,r=20,stroke="#00000",stroke_width = 1,fill=random_color())
petal2 = circle(y=40,r=15,stroke="#00000",stroke_width = 1,fill=random_color())
petal3 = circle(y=20,r=10,stroke="#00000",stroke_width = 1,fill=random_color())
petals = (petal1+petal2+petal3 | repeat(8,rotate(45)))
flower =(bud+petals) | scale(0.25)
show(flower)
show(flower | scale(0.125))