用户:CHN_流星查看:2 回复:2 评论:2 创建时间:2021-08-23T17:40:08
此段代码的错误:
for _count in self.scores:
c = self.dice_answers.count(_count)
dice_answer_count.append(c)
max_answer_index = dice_answer_count.index(max(dice_answer_count))
dice_answer_count[dice_answer_count.index(max(dice_answer_count))] = 0
while dice_answer_count.index(max(dice_answer_count)) in max_answer_index:
max_answer_index = dice_answer_count.index(max(dice_answer_count))
dice_answer_count[dice_answer_count.index(max(dice_answer_count))] = 0
#缩进没问题,报错:TypeError: argument of type 'int' is not iterable
很急!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!