generate all subsets for 2 nd half ( vect2 )
for i in range ( 0 , ( 1 << len ( vect2 ) ) ) : NEW_LINE INDENT value = 1 NEW_LINE for j in range ( 0 , len ( vect2 ) ) : NEW_LINE INDENT if i & ( 1 << j ) : NEW_LINE INDENT value *= vect2 [ j ] NEW_LINE DEDENT DEDENT DEDENT