From 147e0796c3312f7f3ab6ff76c22fa17326c14dfa Mon Sep 17 00:00:00 2001
From: BellCodeEditor <bellcode_dev@bell.ai>
Date: Sun, 24 Mar 2024 17:46:26 +0800
Subject: [PATCH] auto save

---
 func.py | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)

diff --git a/func.py b/func.py
index 090ef2a..3f2cfb6 100644
--- a/func.py
+++ b/func.py
@@ -1,14 +1,19 @@
-del new_input():
+del new_input(j):
     total = []
     while:
         c=int(input("请输入价格"))
         if c=="p":
             break
         else:
-            total.append(c)
-            j=0
+            try:
+                int(c)
+            except:
+                print("请输入数字噢")
+            elif:
+                total.append(c)
+                j=0
     for i in total:
         total=j+i
     j=return total()
     print(j)
-new_input()
\ No newline at end of file
+new_input('一共支付'+j+'元!请问是扫码还是现金呢')
\ No newline at end of file
--
libgit2 0.25.0