From dc67e4e7d897c44b26dc50cce237c1964c1d1356 Mon Sep 17 00:00:00 2001 From: BellCodeEditor <bellcode_dev@bell.ai> Date: Sun, 14 Jul 2024 09:44:34 +0800 Subject: [PATCH] auto save --- diy1.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/diy1.py b/diy1.py index 009e0ab..a5f789f 100644 --- a/diy1.py +++ b/diy1.py @@ -4,11 +4,10 @@ students = ["悟空", "小贝", "八戒", "波奇"] students.pop(2) print(students) # 班上来了一个新同学,名叫"诺依",请将"诺依"加入到班级名单里面 -students.insert(1,"诺依") +students.insert(1) print(students) # 班上准备开始辩论赛,分为红(red)、蓝(blue)组, # 请用切片将班级列表的前2名加入到红组,后2名加入到蓝组 -red = students[:2] -blue = students[2:] + print(red) print(blue) \ No newline at end of file -- libgit2 0.25.0