Commit 8ea03cd8 by BellCodeEditor

save project

parent 22659120
Showing with 10 additions and 2 deletions
...@@ -5,4 +5,12 @@ class A: ...@@ -5,4 +5,12 @@ class A:
self.hp=hp self.hp=hp
self.attack=attack self.attack=attack
b=A("nrt",1,300,6) b=A("nrt",1,300,6)
print(b.name)
\ No newline at end of file def a():
b.level=b.level+1
b.hp=b.hp+200
b.attack=b.attack+200
print(b.level)
a()
a()
\ 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