From 3f10677c91779c0c3369ea5ee56f257295e0d2db Mon Sep 17 00:00:00 2001 From: JackH <1620514129@qq.com> Date: Fri, 4 Jul 2025 21:48:06 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- day4/TODO.py | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/day4/TODO.py b/day4/TODO.py index 5936270..15cf818 100644 --- a/day4/TODO.py +++ b/day4/TODO.py @@ -1,16 +1,15 @@ -list=['原神'] -for i in list: - list.append(input('何事?')) - a=input('何事终了?') +list = ["原神"] +while True: + list.append(input("何事?")) + a = input("何事终了?") if a in list: list.remove(a) else: pass - print('未尽之事:',list) - b = input('是否下一周目(1是2否)') - if b == 1: - continue; + print("未尽之事:", list) + b = input("是否下一周目(1是2否)") + if b == "1": + continue else: - print('未尽之事:',list) - break; -#为什么没用到i也可以用i来进行循环 \ No newline at end of file + print("未尽之事:", list) + break \ No newline at end of file