主页
Python
Python - 添加列表项
demo_list_add_extend_tuple
运行 ❯
×
更改方向
保存代码
更改主题
thislist = ["apple", "banana", "cherry"] thistuple = ("kiwi", "orange") thislist.extend(thistuple) print(thislist)
['apple','banana','cherry','kiwi','orange']