Commit 9e3e0fd5 by BellCodeEditor

save project

parent c281085b
Showing with 7 additions and 7 deletions
...@@ -12,11 +12,10 @@ pen.goto(100,-100) ...@@ -12,11 +12,10 @@ pen.goto(100,-100)
pen.write("你好呀诺依,\n我是悟空",font=("Times",30,"normal")) pen.write("你好呀诺依,\n我是悟空",font=("Times",30,"normal"))
pen.hideturtle() pen.hideturtle()
#画爱心 #画爱心
# pen.penup()
# pen.goto(100,-100)
# turtle.done()
pen1=turtle.Pen() pen1=turtle.Pen()
#1改变爱心大小 #1改变爱心大小
d=s.textinput("提示","你要多大的爱心?")
a=int(d)
len=300 len=300
#2画爱心 #2画爱心
#填充颜色 #填充颜色
...@@ -30,11 +29,11 @@ pen1.pensize(20) ...@@ -30,11 +29,11 @@ pen1.pensize(20)
pen1.color("red") pen1.color("red")
# #
pen1.left(45) pen1.left(45)
pen1.forward(len) pen1.forward(a)
pen1.circle(len/2,180) pen1.circle(a/2,180)
pen1.right(90) pen1.right(90)
pen1.circle(len/2,180) pen1.circle(a/2,180)
pen1.forward(len) pen1.forward(a)
pen1.hideturtle() pen1.hideturtle()
pen1.end_fill() pen1.end_fill()
turtle.done() turtle.done()
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment