##
Find all distinct subset (or subsequence) sums of an array
January 10, 2017

Given a set of integers, find distinct sum that can be generated from the subsets of the given sets and print them in an increasing order. It is given that sum of array elements is small. Examples: Input : arr[] = {1, 2, 3} Output : 0 1 2 3 4 5 6 Distinct subsets… Read More »