python inconsistent use of tabs and spaces in indentation

来源:互联网 发布:泰牛程序员官网 编辑:程序博客网 时间:2024/06/05 06:49

  python 出现的异常inconsistent use of tabs and spaces in indentation意思是:在缩进中不一致地使用制表符和空格,所以python需要很严格的格式,对齐很重要
  解决方法:这个错误是说你用了tab键作缩进了,因为在python不像C/C++里用大括号来区分程序块,而是用缩进所以缩进很重要你把Tab都换成空格就好了

阅读全文
0 0