Commit 988f1eae by BellCodeEditor

save project

parent 4794d14f
Showing with 7 additions and 2 deletions
class Hero:
def __init__(self):
def __init__(self,name,hp,attack):
self.level=1
self.hp=300
self.attast=20
yase=Hero()
bailishoyue=Hero("百里守约",50,9999)
yase=Hero("亚瑟",50,999)
liushan=Hero("刘禅",50,999)
print(bailishoyue.hp)
print(yase.hp)
print(liushan.hp)
\ 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