Commit 3842c0d1 by BellCodeEditor

auto save

parent 37a0c383
try: import func
age = int(input('今年你几岁了?')) data = func.new_input()
except: socre = func.sum(data)
print('要输入整数啊') print("zhegexuanshoudezongdefenshi"+str(socre)) cwate
else: \ No newline at end of file
if age < 18:
print('不可以喝酒哦')
print('程序结束~~')
...@@ -19,6 +19,6 @@ def sum(money): ...@@ -19,6 +19,6 @@ def sum(money):
for i in money: for i in money:
count = count + i count = count + i
return count return count
price = new_input() # price = new_input()
pay = sum(price) # pay = sum(price)
print("宁一共消费了" + str(pay) + "元!扫码还是现金呢?") # print("宁一共消费了" + str(pay) + "元!扫码还是现金呢?")
\ No newline at end of file \ 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