From a5b40de325c1075971f30cee93448c6d9079867a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A5=BD=E5=90=8D=E5=AD=97?= <785702274@qq.com> Date: Mon, 29 Mar 2021 21:21:22 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BA=8F=E5=88=97-=E5=88=97=E8=A1=A8=E5=AE=9E?= =?UTF-8?q?=E8=B7=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- work/3 | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 work/3 diff --git a/work/3 b/work/3 new file mode 100644 index 0000000..daa1d77 --- /dev/null +++ b/work/3 @@ -0,0 +1,22 @@ +# @Author : 20192316贝世之 +# @File : 3.py +# @Time : 2021/3/29 21:04 + +list = ["夏侯淳","凯","李白","诸葛亮"] +print("起始列表:",list) + +list.append("虞姬") +print("增加后的列表:",list) + +list2 = ["大乔","小乔"] +list.extend(list2) +print("合并后的列表:",list) + +list.remove("小乔") +print("删除后的列表:",list) + +list[3] = "周瑜" +print("修改后的列表:",list) + +for i in list: + print("英雄名称:", i) \ No newline at end of file -- Gitee