2018-10-24
閱讀量:
884
python 錯(cuò)誤解析
代碼如下:
>>> t = ()
>>> t[0]
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
IndexError: tuple index out of range
>>> l = []
>>> l[0]
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
IndexError: list index out of range
【錯(cuò)誤分析】空元祖和空列表,沒(méi)有索引為0的項(xiàng)






評(píng)論(0)


暫無(wú)數(shù)據(jù)
CDA考試動(dòng)態(tài)
CDA報(bào)考指南
推薦帖子
0條評(píng)論
0條評(píng)論
0條評(píng)論