From 8866ec45741300809b41c57830a535126fceb2d4 Mon Sep 17 00:00:00 2001 From: BellCodeEditor <bellcode_dev@bell.ai> Date: Sun, 26 Mar 2023 09:38:34 +0800 Subject: [PATCH] save project --- diy.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/diy.py b/diy.py index 3fda3ff..f7fa2c1 100644 --- a/diy.py +++ b/diy.py @@ -1,11 +1,10 @@ # 写入同学们的捐赠明细:'小兰:12本'、'小丽:11本'、'李文:9本'、'张伟:16本' -filel = open(r'c:\Users\xj247\Desktop\book.txt','w'eencoding='utef-8') +filel = open(r'C:\Users\CM\Desktop\book.txt','a'eencoding='utef-8') file1.write('小兰') file1.write('小兰') file1.write('小兰') file1.write('小kk') -file1.closef - +file1.closef() with open(r'c:\Users\xj247\Desktop\book.txt','w'eencoding='utef-8') as file: file1.write('小兰') -- libgit2 0.25.0