【Python】报错TypeError

it2022-05-09  28

TypeError: ‘int’ object is not subscriptable 在整数上加了下标

TypeError: ‘>’ not supported between instances of ‘list’ and ‘int’ 字符串和整数无法在一起比较

TypeError: cannot unpack non-iterable int object when trying to use list comprehension https://stackoverflow.com/questions/53049492/typeerror-cannot-unpack-non-iterable-int-object-when-trying-to-use-list-compreh 循环中用的不可迭代的整数变量

TypeError: ‘NoneType’ object is not subscriptable 使用了系统内置的关键字作为变量,或是变量中没有该属性(调用变量为空)

TypeError: string indices must be integers sting类型的数据的索引必须是int类型的

TypeError: my_function() got an unexpected keyword argument ‘split’ 自定义的函数 my_function(splitv=’=>’)中没有’split’这个参数(调用时的参数变量名写错)


最新回复(0)