Commit 2ed089ea by BellCodeEditor

save project

parent f47689a4
Showing with 21 additions and 0 deletions
class hero:
def __init__(self,name,xueliang,goji,fangyu,dengji):
self.name=name
#self.dengji=dengji
self.xueliang=xueliang
self.goji=goji
self.fangyu=fangyu
yuse=hero("亚瑟",100,20,50,1)
yuse2=hero("后裔",60,80,30,1)
def a():
#yuse.dengji=yuse.dengji+1
yuse.xueliang=yuse.xueliang+100
yuse.goji=yuse.goji+30
yuse.fangyu=yuse.fangyu+40
a()
a()
print(yuse.xueliang)
\ 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