Commit 5145d1bc by BellCodeEditor

save project

parent 22354288
Showing with 13 additions and 0 deletions
class Hero:
def __init__(self,ff,aa):
self.ff=ff
self.aa=aa
def up(self):
self.ff+=1
self.aa+=500
lufei=Hero(1,5000)
lufei.up()
print("路飞的等级为",lufei.ff)
print("路飞的能力为",lufei.aa)
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