Python错误:NoneType对象不是subscriptab

2024-06-16 10:46:11 发布

您现在位置:Python中文网/ 问答频道 /正文

我删去了代码,只显示了我认为与以下错误相关的部分。这是在Python3.x中完成的,因为我正试图自学,所以我以前没有任何Python2.x的经验

谢谢!在

Traceback (most recent call last):
File "rpcombat_refactored.py", line 306, in <module> shopping = buy_equipment()
File "rpcombat_refactored.py", line 242, in buy_equipment
print("You have a", join_with_and(profile['inventory']), "in your bag.")
File "rpcombat_refactored.py", line 94, in join_with_and elif sequence < 1:
TypeError: unorderable types: list() < int()

代码:

^{pr2}$

Tags: and代码inpy错误withlinebuy