Hey @Vidushi04
Your code is very well written and the logic is perfectly right.
But this question can have two correct answers corresponding to various test cases like:
Input:
abc
acb
Output:
Both “ac” and “ab” can be the answers here depending on the logic used in the code.
It’s just that at backend user input is matched with a standard file.
So just interchanging str1 and str2 in line 43 and 44 of your code, would fetch you correct output. I’ve made this change in your code. https://ide.codingblocks.com/s/51699
Hope you understand