Commit 3beb03bb by BellCodeEditor

save project

parent 05e7d622
def md(): # md 是买单的意思
total = []
while True: #记录5行和11的 数字
try:
unit= input("尊敬的 VIP 9999999 客户请输入:")
if unit== 'q':
break
else:
total.append(int(unit))
except:
input("尊敬的 VIP 9999999 客户请输入:")
return total #返回值
#求和
def qiouhe(qqq):# qqq 是形参
abh=0
for i in qqq:
abh+=i
return abh
x = qiouhe(md())
#打印结果
print(x)
\ No newline at end of file
import func
fengshu=func.md()
fengshu_zhenfeng=func.qiouhe(fengshu)
print(fengshu_zhenfeng)
\ 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