|
马上注册,结交更多好友,享用更多功能^_^
您需要 登录 才可以下载或查看,没有账号?立即注册
x
我在idle上输入了七十多八十行代码,但是一直无法保存,按f5键保存也一直没反应,一直要求保存,在前面加#coding=utf-8也没有用,真心求助哪个大佬可以帮帮我
代码如下
from turtle import *
from time import sleep
def go_to(x,y):
up()
goto(x,y)
down()
def big_Circle(size):
speed(5)
for i in range(150)
forward(size)
right(0.30
def small_Circle(size):
speed(10)
for i in range(210)
forward(size)
right(0.786)
def line(size):
speed(5)
forward(51*size)
def heart( x, y, size):
go_to(x,y)
left(150)
begin_fill()
line(size)
big_Circle(size)
small_Circle(size)
big_Circle(size)
line(size)
end_fill()
def arrow():
pensize(10)
setheading(0)
go_to(-400,0)
left(15)
forward(150)
go_to(339,178)
forward(150)
def arrowHead():
pensize(1)
speed(5)
color('red','red')
begin_fill()
left(120)
forward(20)
right(150)
forward(35)
right(120)
forward(35)
right(150)
forward(20)
end_fill()
def main():
pensize(4)
color('red','red')
#getscreen(),tracer(30,0)
heart(200, 0, 1)
setheading(0)
heart(-80, -100, 1.5)
arrow()
arrowHead()
go_to(400, -300)
done()
main()
|
|