Commit 2f1305c2 by BellCodeEditor

save project

parent 05576102
from turtle import*
q=["red","orange","yellow","green","blue","purple","darkorchid"]
for i in range(7):
fillcolor(q[i])
begin_fill()
circle(50)
end_fill()
left(360/7)
done()
hideturtle()
from turtle import*
pencolor("pink")
fillcolor("blue")
begin_fill()
for i in range(8):
circle(100,90)
left(135)
end_fill()
done()
from turtle import*
pencolor("pink")
fillcolor("blue")
begin_fill()
for i in range(8):
circle(50,120)
left(105)
end_fill()
done()
from turtle import*
for i in range(6):
fd(50)
right(60)
left(120)
for j in range(6):
for i in range(5):
fd(50)
right(60)
right(120)
done()
w=int(input("你的语文成绩是多少?"))
e=int(input("你的数字成绩是多少?"))
r=int(input("你的英语成绩是多少?"))
print("你的总分为:",w+e+r,"平均分为:",(w+e+r)/3)
\ No newline at end of file
from turtle import*
right(180)
fd(50)
left(90)
circle(50,360)
left(90)
fd(100)
left(90)
circle(50,90)
left(90)
fd(100)
hideturtle()
done()
class Person:
def __init__(self,name,age):
self.name = name
self.age = age
class Teacher(Person):
def __init__(self,name,age,subject):
self.subject = subject
super().__init__(name,age)
def skill(self):
print(self.subject)
qq=Teacher("ww",11,"ee")
qq.skill()
\ No newline at end of file
import random
class Hero: # 英雄类
def __init__(self, name): # 实例属性
self.name = name
......@@ -43,5 +44,11 @@ print("-"*30)
print(" 开始战斗")
while True:
print("-"*30)
print("请选择释放英雄技能(1攻击/2治疗):")
a=input("请选择释放英雄技能(1攻击/2治疗):")
if a=="q":
print("结束战斗")
break
eilf a=="1":
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