Commit c5226e98 by BellCodeEditor

save project

parent b2fc3008
Showing with 7 additions and 4 deletions
class Hero:
def __init__(self):
def __init__(self,name,hp,gj):
self.level=1
self.hp=200
self.gj=20
self.name=name
self.hp=hp
self.gj=gj
yase=Hero()
yase=Hero("亚瑟",200,20)
hoyi=Hero("后羿",240,23)
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