Commit 18d4c9b3 by BellCodeEditor

save project

parent 26fdebc3
Showing with 26 additions and 18 deletions
b=['袁术','公孙瓒','关羽','张飞','刘备','曹操'] import turtle
b.pop(3) #背景
b.pop(-2) screen=turtie.Screen()
b.remove('曹操') screen.bgcolor("red")
print(b) #写字
#添加 pen=turtle.Pen()
b=['袁术','公孙瓒','关羽'] pen.penup()
b.append('曹操') pen.goto(100,-100)
b.insert(2,'张飞') pen.write("你好~\n乡巴佬国王",font=("times",0,"normal"))
print(b) pen.hideturtle()
#列表添加 #画爱心
a=['吕布','董卓'] pen1=turtle.Pen()
b=['关羽','张飞','刘备'] pen1.pencolor("green")
c=['曹操','袁术','诸葛亮','公孙瓒','颜良','文丑'] pen1.pensize(5)
a.extend(b) a=screen.textinput("提示","你需要多大的爱心")
a.extend(c[1:5]) lovesize=int(a)
print(a)`` pen1.left(45)
\ No newline at end of file pen1.forward(2*lovesize)
pen1.circle(lovesize,180)
pen1.right(90)
pen1.circle(lovesize,180)
pen1.forward(2*lovesize)
pen.hideturtle()
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