利用a.index(target)
其中a是目标list,target是需要的目标值
a = [1,5,8,9,b]
print(a.index(5))
#输出索引值为1
获取最值的索引:
list.index(max(s))
list.index(min(s))