t=0W=[2,2,2,3,3,3,5,5,5,5,8,8]UW=[2,3,5,8]Tfit=[12,24,25]forjinrange(len(UW)):t=t+sum(W.count(UW[j])*max(Tfit)/len(W))错误提示:Traceback(mostrecentcalllast):File"C:/Users/zb/Desktop/compute.py",line6,int=t+sum(W.count(UW[j])*max(Tfit)/len(W))TypeError:'float'objectisnotiterable去掉“/len(W)”时,显示:TypeError:'int'objectisnotiterable
添加回答
举报
0/150
提交
取消