Commit 8533eee3 by BellCodeEditor

save project

parent 22354288
Showing with 19 additions and 0 deletions
LV=1
class hero:
def __init__(self,name,HP,ADC,LV):
self.LV=1
self.name=name
self.HP=HP
self.ADC=ADC
yase=hero("亚瑟",300,20,1)
houyi=hero("后羿",250,23,1)
def YaseUpgrade():
yase.LV=yase.LV+1
yase.HP=yase.HP+150
yase.ADC=yase.ADC+5
YaseUpgrade()
YaseUpgrade()
print("亚瑟的等级为"+str(yase.LV)+"级")
\ 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