📜  python if index not out of range - Python代码示例
📅  最后修改于: 2022-03-11 14:45:56.440000             🧑  作者: Mango
代码示例1
def double_index(lst, index):
try:
lst[index] = lst[index] * 2
except IndexError:
return lst