Python 空字符串转化问题:ValueError: invalid literal for int() with base 10: ' ',原因及解决方法。
生活随笔
收集整理的这篇文章主要介绍了
Python 空字符串转化问题:ValueError: invalid literal for int() with base 10: ' ',原因及解决方法。
小编觉得挺不错的,现在分享给大家,帮大家做个参考.
ValueError: invalid literal for int() with base 10: ' '
翻译:
值异常:以10为基数的int()的无效文字:’ ’
int('')就会报错。
就是说 不能把空字符串转化为10进制整数。
喜欢的点个赞❤吧!
总结
以上是生活随笔为你收集整理的Python 空字符串转化问题:ValueError: invalid literal for int() with base 10: ' ',原因及解决方法。的全部内容,希望文章能够帮你解决所遇到的问题。
- 上一篇: Python+selenium 自动化-
- 下一篇: Python 修改tuple元组提示:T