Check whether sum is equal to target if it is equal , then print the subset
if ( sum == target ) : NEW_LINE INDENT print ( " { " , end = " " ) ; NEW_LINE for i in range ( len ( sets ) ) : NEW_LINE INDENT if ( x [ i ] == 1 ) : NEW_LINE INDENT print ( sets [ i ] , end = " , ▁ " ) ; NEW_LINE DEDENT DEDENT print ( " } , ▁ " , end = " " ) ; NEW_LINE DEDENT