Commit fb3bd71c by BellCodeEditor

save project

parent ba3533df
Showing with 18 additions and 7 deletions
class i():
def __init__(self,a,b,c):
d=1
self.hp=a
self.at=b
y=i("亚瑟","300","20")
h("后羿","240","23")
class i:
def __init__(self,name,hp,at):
self.level=1
self.name=name
self.hp=hp
self.at=at
y=i("亚瑟",300,20)
def q():
y.level=y.level+1
y.hp=y.hp+50
y.at=y.at+4
q()
q()
print(y.level)
print(y.name)
print(y.hp)
print(y.at)
\ 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