Commit 7111b801 by BellCodeEditor

save project

parent 352efaea
Showing with 6 additions and 6 deletions
import turtle
import random
len=random.randint(40,60)
screen=turtle.Screen()
screen.bgcolor("pink")
len=screen.textinput("温馨提示","你想要多大的爱心呀")
pen=turtle.Pen()
pen.hideturtle()
pen.penup()
......@@ -13,9 +12,9 @@ pen_2.hideturtle()
pen_2.pensize(5)
pen_2.pencolor("red")
pen_2.left(45)
pen_2.forward(2*len)
pen_2.circle(len,180)
pen_2.forward(2*float(len))
pen_2.circle(float(len),180)
pen_2.right(90)
pen_2.circle(len,180)
pen_2.forward(2*len)
pen_2.circle(float(len),180)
pen_2.forward(2*float(len))
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