Commit f4d114af by BellCodeEditor

save project

parent a85c7e21
Showing with 10 additions and 4 deletions
class Hure:
def__init__(self,name,hp,attack):
def __init__(self,name,hp,attack):
self.level=1
self.name=name
self.hp=hp
self.attack=attack
yasa=Hure("",,)
print(yasa.name,hp,attack)
\ No newline at end of file
bq=Hure("bq",300,10)
def upgrade():
bq.level=bq.level+1
bq.hp=bq.hp+50
bq.attack=bq.attack+4
upgrade()
upgrade()
print(bq.level)
\ 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