Commit b18439db by BellCodeEditor

auto save

parent d6c81a0f
Showing with 11 additions and 0 deletions
class Heros:
def __init__(self,name,attack,hp):
self.name=name
self.level=1
self.attack=attack
self.hp=hp
wukong=Heros("悟空",36,500)
yase=Heros("亞瑟",36,500)
print(yase.name+"的hp:"+str(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