Commit fe66cbcd by BellCodeEditor

save project

parent 6fcfac6d
Showing with 15 additions and 6 deletions
def ikun(): def ikun():
total = [] total = []
while True: while True:
unit=int( input("请输入:")) unit=input("请输入:")
if unit== 'q': if unit== 'q':
break break
else: else:
total.append(unit) try:
print(total)
total.append(int(unit))
try: except:
ikun()
except:
print('这都能错,小垃圾') print('这都能错,小垃圾')
nim=0
for i in total:
nim+=i
# print(total)
return nim
skj=ikun()
print(skj)
\ 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