抱歉,如果这个问题已经在其他地方得到了回答,但我不确定具体的术语可以找到它。你知道吗
我想用这个代码做的是:
当我试图运行这个我得到的错误。 运行时错误(IndexOutOfRangeException):索引超出范围:1
有谁能提出更好的方法吗/告诉我哪里出了问题谢谢!你知道吗
groundtempCtext = []
groundtempCtext.append(min(groundtempall))
for i in range(1,len(divisionPts1)):
c = (max(groundtempall)-min(groundtempall))/(len(divisionPts1)-1)
groundtempCtext.append(c+groundtempCtext[i-1])
groundtempCtext.append(max(groundtempall))
你可以用列表代替循环。你知道吗
我只想记录总数,你可以使用列表comp,但循环更容易理解:
我还将变量改为使用下划线,这是python方法。你知道吗
相关问题 更多 >
编程相关推荐