Commit b35d012a by BellCodeEditor

save project

parent 7f4bdc7b
Showing with 9 additions and 11 deletions
total = [] total = []
def A(): def A():
while True: while True:
try: try:
unit= int(input("请输入:")) unit= int(input("请输入:"))
except: except:
print('请输入数字') print('请输入数字')
else:
if unit == 1:
break
else: else:
if unit == 1:
break
total.append(unit) total.append(unit)
return unit
A() A()
print(total) print(total)
\ 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