It depends on what you mean. You could simply subtract the sum of the remaining numbers from the first, for example:
def diffr(items):
return items[0] - sum(items[1:])
, , ; , , :
x0 - x1 - x2 - x3 -... - xn = x0 - (x1 + x2 + x3 +... + xn)
, , diffr() .
, x0 , args x1 xn. sum(args) . , ... , , ?