Commit 2c2bd72f by BellCodeEditor

save project

parent 419c2549
Showing with 8 additions and 5 deletions
class Hero: class Hero:
def __init__(self,name,hp,attack) def __init__(self,name):
self.name = name self.level = 1
self.hp = 400 self.hp = 250
self.attack = 40 self.attack = 40
\ No newline at end of file self.name = name
yase=Hero("亚瑟")
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