画奥运五环

coordA=(-110,0,110,-55,55)
coordB=(-25,-25,-25,-75,-75)
cl=("red","blue","green","yellow","black")
#高级应用,画固定大小的奥运五环,半径45
import turtle
turtle.pensize(5)
turtle.speed(0)
for i in range (5):
    turtle.color(cl[i])
    turtle. penup()
    turtle.goto(coordA[i],coordB[i])
    turtle.pendown()
    turtle.circle(45)
turtle.hideturtle()  #隐藏箭头
turtle.done()

posted @ 2020-11-02 19:43  大兔xx  阅读(155)  评论(0)    收藏  举报