Commit 09307a10 by BellCodeEditor

auto save

parent a32ab965
Showing with 2201 additions and 19 deletions
import turtle
p=turtle.Pen()
p.forward(200)
p.right(90)
p.forward(200)
p.right(90)
p.forward(200)
p.right(90)
p.forward(200)
p.right(90)
p.up()
p.goto(100,0)
p.pendown()
p.fillcolor('red')
p.begin_fill()
p.goto(200,-100)
p.goto(100,-200)
p.goto(0,-100)
p.goto(100,0)
p.end_fill()
p.hideturtle()
turtle.done()
\ No newline at end of file
import turtle as l
l.speed(1)
for i in range(4):
l.forward(200)
l.right(90)
l.penup()
l.goto(100,0)
l.pendown()
l.fillcolor("red")
l.begin_fill()
l.goto(200,-100)
l.goto(100,-200)
l.goto(0,-100)
l.goto(100,0)
l.end_fill()
l.hideturtle()
l.done()
import turtle
turtle.screensize(600,800,"green")
turtle.shape( "turtle")
turtle.pencolor("white")
turtle.pensize(20)
turtle.speed(10)
turtle.forward(200)
turtle.left(90)
turtle.forward(200)
turtle.left(90)
turtle.forward(200)
turtle.left(90)
turtle.forward(200)
turtle.left(180)
turtle.forward(200)
turtle.right(25)
turtle.forward(200)
turtle.right(122)
turtle.forward(200)
turtle.penup()
turtle.right(90)
turtle.forward(130)
turtle.pendown()
turtle.circle(10)
turtle.penup()
turtle.forward(200)
turtle.right(p)
turtle.done()
class Dog: # 狗类
def __init__(self):
self.footNum = 4 # 腿
self.eyeNum = 2 # 眼睛
self.head = 1 # 头
self.earsNum = 2 # 耳朵
self.skin = "white"
def run(self):
print("狗狗飞快的跑起来")
class Husky(Dog): # 哈士奇类
def __init__(self):
??
coco = Husky()
print(coco.skin)
\ 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