Commit 8473488c by BellCodeEditor

save project

parent afc1eaf0
Showing with 12 additions and 0 deletions
class Haro:
def __init__(self,name,hp,attack):
self.level=1
self.name=name
self.hp=hp
self.attack=attack
pipy=Haro("pipy",2233,555776)
xiaoba=Haro("xiaoba",2233,555776)
print("pipy的血量值为:",pipy.hp)
print("xiaoba的血量值为:",xiaoba.hp)
\ 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