Commit aec54ef0 by BellCodeEditor

save project

parent 05e7d622
import func
data=func.superidol()
score=func.sum(data)
print("这位选手的总分数为:"+str(score))
\ No newline at end of file
def superidol():
total=[]
while True:
unit=input('?')
if unit=='q':
break
else:
try:
unit=int(unit)
except:
print("鬼!")
else:
total.append(unit)
finally:
print("-"*30)
return total
result=superidol()
print(result)
money=[]
def sum(money):
b250=0
for i in money:
b250=b250+i
return b250
gui=[520,1314,666,114514,208200]
con=sum(gui)
print(con)
\ 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