成功解决Python中出现的TypeError: object of type 'zip' has no len()
生活随笔
收集整理的這篇文章主要介紹了
成功解决Python中出现的TypeError: object of type 'zip' has no len()
小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.
成功解決Python中出現(xiàn)的TypeError: object of type 'zip' has no len()
不羅嗦,直接解決問題!
?
?
目錄
解決問題
解決思路
解決方法
?
?
解決問題
TypeError: object of type 'zip' has no len()
?
?
?
解決思路
類型錯誤:“zip”類型的對象沒有l(wèi)en()方法
參考國外網(wǎng)友回答:
?
?
解決方法
將 ? ? print(len(training_data))?
改為 ?print(list(training_data))
大功告成!哈哈!
?
?
?
?
總結(jié)
以上是生活随笔為你收集整理的成功解决Python中出现的TypeError: object of type 'zip' has no len()的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 成功解决Python3版UnicodeD
- 下一篇: 成功解决AttributeError: