Commit eba2d4c3 by BellCodeEditor

save project

parent 0c7f5fd4
Showing with 12 additions and 6 deletions
class hero:
def __init__(self):
self.hp=1000
def __init__(self,name,hp,sttack):
self.level=1
anqila=hero()
print(anqila.hp)
\ No newline at end of file
self.name=name
self.hp=hp
a=hero('a',1,1)
q=hero('q',1,5000)
anqila=hero('anqila',5000,1)
print(anqila.hp)
print(a.hp)
print(q.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