Commit c476c1e4 by BellCodeEditor

auto save

parent eec9df08
Showing with 6 additions and 9 deletions
...@@ -4,6 +4,7 @@ class Hero: ...@@ -4,6 +4,7 @@ class Hero:
self.name=name self.name=name
self.hp=hp self.hp=hp
self.attack=attack self.attack=attack
def aaa(): def aaa():
yase.level=yase.level+1 yase.level=yase.level+1
yase.hp=yase.hp+100 yase.hp=yase.hp+100
...@@ -13,16 +14,11 @@ yase = Hero("垭瑟",300,20) ...@@ -13,16 +14,11 @@ yase = Hero("垭瑟",300,20)
houyi = Hero("后羿",200,40) houyi = Hero("后羿",200,40)
aaa() aaa()
aaa()
aaa()
aaa()
aaa()
aaa()
aaa()
aaa()
aaa()
print('_'*20)
print(yase.level) print(yase.level)
print('_'*20)
print(yase.hp) print(yase.hp)
print('_'*20)
print(yase.attack) print(yase.attack)
print('_'*20)
\ 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