题库 Python题库 题目列表 已知列表cities = ['beijing', 'shanghai...
单选题

已知列表cities = ['beijing', 'shanghai', 'guangzhou', 'shenzhen'],以下哪个命令可以删除最后一个列表元素'shenzhen'?( )

A.

cities.del()

B.

cities.pop()

C.

cities.remove()

D.

cities.pop(4)

题目信息
2025年 3月 选择题
63%
正确率
0
评论
64
点击