def checkio(stones):

    def subcheckio(stones, left, rite):
        if len(stones) == 0:
            return abs(left - rite)
scores = []
nstones = stones[1:]
scores.append(subcheckio(nstones, left + stones[0], rite))
scores.append(subcheckio(nstones, left, rite + stones[0]))
return min(scores)
return subcheckio(stones, 0, 0)
How to calculate a number representing the lowest possible weight difference