Python: Objects initialized the same way affect each other

后端 未结 0 601
花落未央
花落未央 2020-12-23 22:17

I\'m creating a class like the following in Python:

stat_list = [\'Health\', \'Strength\', \'Stamina\']

empty_stats = dict.fromkeys(stat_list, 0)


class Sta         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题