Commit 8601091a by BellCodeEditor

save project

parent 91286450
Showing with 5 additions and 2 deletions
...@@ -4,6 +4,7 @@ def new_input(): ...@@ -4,6 +4,7 @@ def new_input():
unit= input("请输入:") unit= input("请输入:")
if unit== 'q': if unit== 'q':
break break
else:
try: try:
unit=int(unit) unit=int(unit)
except: except:
...@@ -11,5 +12,6 @@ def new_input(): ...@@ -11,5 +12,6 @@ def new_input():
else: else:
total.append(unit) total.append(unit)
print("$"*30) print("$"*30)
print(total) return total
new_input() a=new_input()
print(a)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment