def part_sum2(x_table):
    """All subsetsums from a list x

    :param x_table: list of values
    :complexity: :math:`O(2^{len(x)})`
    """
    answer = set([0])        # 0 = value of empty set
    for xi in x_table:
        answer |= set(value + xi for value in answer)
    return answer