Commit 09f7896c by BellCodeEditor

save project

parent 3b575b4e
Showing with 10 additions and 8 deletions
class hero: class Hero:
def __hero__(self): def __init__(self, name , hp , attach):
self.level=1 self.level = 1
self.hp=300 self.name = name
self.attack=20 self.hp=hp
self.attach=attach
yase=hero()
\ No newline at end of file yase=Hero("亚瑟",300,20)
print("亚瑟的血量为:"yase.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