Commit 078eba58 by BellCodeEditor

save project

parent c5e4459b
Showing with 21 additions and 10 deletions
#total = []
def x():
#while True:
try:
int(input("请输入:"))
except:
print("请输入整数")
else:
print()
print("程序结束")
x()
total = []
while True:
input("请输入单价:(按'p'退出)")
if y=="p":
break
else:
try:
y=int(y)
except:
print("请输入整数")
else:
total.append(total)
#print("程序结束")
return total
totai=x()
print(totai)
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