实例代码
# coding:utf8
import turtle
turtle.setup(500, 500)
turtle.reset()
turtle.pensize(5)
turtle.penup()
turtle.goto(0, -200)
turtle.pendown()
# 绘制红边框蓝填充颜色的大圆
turtle.color("red", "blue")
turtle.begin_fill()
turtle.circle(200)
turtle.end_fill()
# 绘制红边框绿填充颜色的大圆
turtle.color("red", "green")
turtle.begin_fill()
turtle.circle(150)
turtle.end_fill()
# 绘制红边框黄填充颜色的大圆
turtle.color("red", "yellow")
turtle.begin_fill()
turtle.circle(100)
turtle.end_fill()
turtle.done()
运行结果