Commit 83acaee4 by BellCodeEditor

save project

parent d6c81a0f
Showing with 17 additions and 0 deletions
class Hole:
def __init__(self,name,sudu,gongji,shenming):
self.lkj=1
self.name=name
self.sudu=sudu
self.gongji=gongji
self.shenming=shenming
lanseyaoji=Hole("蓝色妖姬",6000,150,200)
hongsefenbao=Hole("红色风暴",200,400,500)
def abc():
lanseyaoji.lkj=lanseyaoji.lkj+1
lanseyaoji.sudu=lanseyaoji.sudu+150
lanseyaoji.gongji=lanseyaoji.gongji+200
lanseyaoji.shenming=lanseyaoji.shenming+300
abc()
print("蓝色妖姬的素性",lanseyaoji.sudu,lanseyaoji.gongji,lanseyaoji.shenming)
\ 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