玫瑰花
from
turtle
import
*
setup(
0.3
,
0.9
)
speed(
0
)
begin_fill()
fillcolor(
"red"
)
circle(
80
,
20
)
circle(
5
,
150
)
circle(
160
,
20
)
circle(
6
,
150
)
circle(
200
,
18
)
circle(
15
,
160
)
circle(
80
,
30
)
circle(
240
,
10
)
a
=
pos()
a1
=
heading()
a2
=
a1
-
180
seth(
-
90
)
fd(
35
)
l1
=
pos()
seth(
120
)
fd(
10
)
seth(
-
100
)
fd(
10
)
circle(
80
,
80
)
l2
=
pos()
seth(
8
)
circle(
80
,
80
)
circle(
240
,
10
)
end_fill()
seth(
-
120
)
fd(
35
)
r1
=
pos()
circle(
-
80
,
20
)
circle(
80
,
53
)
seth(
30
)
circle(
25
,
125
)
circle(
-
100
,
36
)
goto((l1))
seth(
90
)
fd(
35
)
seth(a2)
circle(
-
240
,
10
)
circle(
-
80
,
30
)
circle(
-
15
,
80
)
goto((r1))
pu()
goto((l2))
pd()
pensize(
4
)
pencolor(
"green"
)
seth(
-
100
)
circle(
100
,
40
)
fd(
100
)
g1
=
pos()
g2
=
heading()
pensize(
2
)
pencolor(
"green"
)
pu()
fd(
-
100
)
seth(
10
)
pd()
circle(
200
,
10
)
pensize(
1
)
pencolor(
"black"
)
pu()
left(
180
)
circle(
-
200
,
6
)
pd()
left(
180
)
begin_fill()
fillcolor(
"green"
)
seth(
-
30
)
circle(
60
,
120
)
seth(
150
)
circle(
60
,
120
)
end_fill()
seth(
10
)
circle(
200
,
16
)
pensize(
2
)
pencolor(
"green"
)
pu()
goto((g1))
pd()
seth((g2))
fd(
-
20
)
seth(
170
)
circle(
200
,
8
)
pensize(
1
)
pencolor(
"black"
)
begin_fill()
fillcolor(
"green"
)
seth(
-
120
)
circle(
-
60
,
120
)
seth(
60
)
circle(
-
60
,
120
)
seth(
170
)
circle(
200
,
16
)
end_fill()