Commit 0282c647 by BellCodeEditor

save project

parent 7a54483a
Showing with 12 additions and 1 deletions
......@@ -4,6 +4,7 @@ def a():
unit= input("请输入:")
try:
if unit== 'q':
return total
break
else:
total.append(unit)
......@@ -11,6 +12,15 @@ def a():
print("输入整数")
else:
print(total)
return total
a=a()
print(a)
def sum(x):
sum=0
for i in sum:
sum=sum+i
return sum
a=sum(a)
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