python 通过索引删除列表中类

pop属于列表中的一个函数,通过索引进行删除。
a=['w','e','r']
a.pop(1)
print(a)
输出
['w', 'r']
posted @ 2021-08-30 22:19  祥瑞哈哈哈  阅读(309)  评论(0编辑  收藏  举报