Regarding this question


sir I don’t what do next to compare these string laxographically

hey @sraj39273 for input: acb
Expected output is:
bac
bca
cab
cba
Yours is giving is:
acb
abc
cab
cba
bca
bac
Do what, store each output sting in a vector of string, and then sort them. Then print that string vector, all your test cases will get passed.
Take this for reference

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.