-2
当我运行我的代码时,在for
循环行中出现错误。for循环IndentationError:意外缩进
这是错误:
File.readlines(): IndentationError: unexpected indent
这是我的代码:
File = open('/home/shar/Desktop/list','r')
for line in File.readlines():
有什么想法?
那么,你缩进'for'行。你为什么这么做? – BrenBarn