None of the test case passing


none of the test case passing after hitting submit button but working for manual test cases

Your code is also considering the empty subset. So the output of your code will always be Yes.
To correct it, just change the condition of printing Yes to if(count > 1).
Also in lines 12 and 13, pass the same original array arr in the recursive function. No need to pass arr+1.

thank you @S19APP-PP0108
it is now working.

1 Like