1 import turtle #匯入turtle模組
2 turtle.color("blue") #定義顏色
3 turtle.penup() #penup和pendown()設定畫筆抬起或放下時是否繪製直線
4 turtle.goto(-110,-25) #初始位置以中心座標為(0,0)
5 turtle.pendown()
6 turtle.circle(45) #繪製圓的半徑
7
8 turtle.color("black")
9 turtle.penup()
10 turtle.goto(0,-25)
11 turtle.pendown()
12 turtle.circle(45)
13
14 turtle.color("red")
15 turtle.penup()
16 turtle.goto(110,-25)
17 turtle.pendown()
18 turtle.circle(45)
19
20 turtle.color("yellow")
21 turtle.penup()
22 turtle.goto(-55,-75)
23 turtle.pendown()
24 turtle.circle(45)
25
26 turtle.color("green")
27 turtle.penup()
28 turtle.goto(55,-75)
29 turtle.pendown()
30 turtle.circle(45)
1 import turtle #匯入turtle模組
2 turtle.color("blue") #定義顏色
3 turtle.penup() #penup和pendown()設定畫筆抬起或放下時是否繪製直線
4 turtle.goto(-110,-25) #初始位置以中心座標為(0,0)
5 turtle.pendown()
6 turtle.circle(45) #繪製圓的半徑
7
8 turtle.color("black")
9 turtle.penup()
10 turtle.goto(0,-25)
11 turtle.pendown()
12 turtle.circle(45)
13
14 turtle.color("red")
15 turtle.penup()
16 turtle.goto(110,-25)
17 turtle.pendown()
18 turtle.circle(45)
19
20 turtle.color("yellow")
21 turtle.penup()
22 turtle.goto(-55,-75)
23 turtle.pendown()
24 turtle.circle(45)
25
26 turtle.color("green")
27 turtle.penup()
28 turtle.goto(55,-75)
29 turtle.pendown()
30 turtle.circle(45)