Whats wrong with this solution

@niketagarwal10 simply sorting wont work because the strings with smaller length are placed before the strings which are longer. so your code will fail in a case for eg where 9009 and 90 are present. The sorted order will be 909009 and so you will print the reverse order 900990 but a bigger number is possible.
You can use the custom sort function to see if s1 + s2 is bigger or s2 + s1 and sort accordingly.

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.