Whats wrong with my code?

i have fixed all the errors

  1. use string not char array
    because c>d this will work if c and d are strings only

  2. call the recursion inside for loop and also add backtrack condition

  3. also store all possible answers in a vector and in main() sort and print the vector

Modified Code

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.