Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
one string solution with itertools combinations solution in Clear category for Loading Cargo by kdim
from itertools import combinations
def checkio(data):
return min([abs(sum(data) - sum(j) * 2) for i in range(len(data)) for j in combinations(data, i)])
Jan. 23, 2021
Comments: