Commit d16f4b32 by BellCodeEditor

save project

parent 86212bb5
Showing with 17 additions and 2 deletions
class class Hero:
\ No newline at end of file def __init__(self,name,hp,attack):
self.level = 200000000000000000000000000000000000000000000000000000000000000000000000000000000000
self.name = name
self.HP = 9999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999
self.attack = 9999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999
kai = Hero('凯',99999999999999,99999999999999999)
mozi = Hero('墨子',99999999999999,99999999999999999)
print('等级:%s'%kai.level)
print('血量:%d'%kai.HP)
print('攻击:%d'%kai.attack)
print('等级:%s'%mozi.level)
print('血量:%d'%mozi.HP)
print('攻击:%d'%mozi.attack)
\ 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