TabError: Inconsistent use of tabs and spaces in indentation

  • Post author:
  • Post category:其他


Pyhton 编辑错误

问题:

TabError: Inconsistent use of tabs and spaces in indentation


解决方法:

这个错误是说你用了tab键作缩进了,

因为在python不像C/C++里用大括号来区分程序块,而是用缩进

所以缩进很重要你把


Tab


都换成


空格


就好了



版权声明:本文为gdp12315_gu原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。