Why this code of my not getting Accepted, it is giving the correct output.
Code link: https://ide.codingblocks.com/s/83540
Problem: Recursion All Subsequences -> link
Recursion All Subsequences
Got it! Since my vector is declared globally so, previously stored output from different test cases are getting printed in the next iteration.
Cleared the vector and it worked!
can you please tell me how you overcame this problem…!!!
I am not sure if you still need help with this. But since there are multiple test-cases hence for the upcoming test cases our vector will be having some elements already. Hence we need to start fresh, by resetting the vector.