From b56aa9ba7ba273a05c1b516b00839a7964c45e2c Mon Sep 17 00:00:00 2001 From: BellCodeEditor <bellcode_dev@bell.ai> Date: Sat, 16 Oct 2021 17:05:25 +0800 Subject: [PATCH] save project --- diy1.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/diy1.py b/diy1.py index 89f4b83..e301176 100644 --- a/diy1.py +++ b/diy1.py @@ -1,10 +1,13 @@ # 利用write()帮助悟空给诺依回信吧~ import turtle pen=turtle.Pen() +screen=turtle.Screen() +screen.bgcolor("lightpink") pen.penup() pen.goto(100,-100) pen.write("诺依\n你吃了吗?\n好吃吗?",font=("Times",30,"normal")) -len=100 +a=screen.textinput("问题","大小") +len=int(a) pen.hideturtle() pen1=turtle.Pen() pen1.pensize(5) @@ -15,8 +18,7 @@ pen1.circle(len,180) pen1.right(90) pen1.circle(len,180) pen1.forward(2*len) -screen=turtle.Screen() -screen.bgcolor("lightpink") + pen1.hideturtle() turtle.done() -- libgit2 0.25.0