报错:TypeError: object of type ‘numpy.int32’ has no len()
报错代码:len(np.random.choice(np.arange(0, 10)))
报错原因:len(int)
是不对的,传参不能为int类型,需要为可迭代序列,改为len(range(int))
TypeError: object of type ‘numpy.int32‘ has no len()报错原因
于 2022-10-01 14:05:45 首次发布