Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Restricted Sum by voxes96
def checkio(data):
s = 0
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
s = s + data.pop()
if(len(data) == 0):
return s
return s
Oct. 29, 2016