您的位置:首页 > 编程语言 > Python开发

小白python疑难|IndentationError: unexpected indent

2019-02-04 21:23 281 查看

python

学习python,出现了第一个错误。
File “<pyshell#113>”, line 2
thistuple = (“apple”, “banana”, “cherry”)
^
IndentationError: unexpected indent

解决方法:把变量“thistuple”前面的空格去掉即可。因为python的缩进规则比较严格,所以不要随便加空格缩进。

下图正常运行。

内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: