python:IndentationError:expected an indented block错误

学文本进度条时,因为在IDLE中"\r"不可用,所以到cmd中模拟。

报错“IndentationError: expected an indented block”

发现原因是没有缩进。。。我还以为那个省略号就是缩进呢。。。

Python语言对缩进太敏感了,以后记住:

遇到:if, def, for xxx

该缩就缩!

相关文章:

  • 2022-12-23
  • 2021-06-02
  • 2021-10-18
  • 2021-06-17
  • 2021-08-25
猜你喜欢
  • 2021-10-21
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2021-06-12
相关资源
相似解决方案