import turtle
turtle.bgcolor('black')
turtle.title('Welcom star')
turtle.setup(800,600)
colors=['green','red','cyan','pink','purple','blue','yellow','orange']
tpen=turtle.Pen()
y=len(colors)
for x in range (1,101):
tpen.color(colors[x%y])
tpen.fd(x*10)
tpen.left(90)
turtle.mainloop()
注意:本文归作者所有,未经作者允许,不得转载