My turtle

Spiral

 

Task: Build spiral


Code:

from turtle import *
speed(0)
bgcolor('black')
colors = ['cyan','light yellow','yellow']
for i in range (360):
    pencolor(colors[i%3])
    forward(i*2+0)
    right(120+1/3)
hideturtle()
done()

2026-07-10 08:16:37

Comments

No comments yet. Be the first to leave one!

Leave a Comment