I am unable to understand the mistake.
please explain with an example why am I getting WA.
2 test cases are wrong
Consider the testcase:
15
78 7 62 28 73 68 94 88 65 61 59 21 92 4 97
90
in this, ur code do not give the answer in lexiographical order
Thanks. Now I got it.
please mark your doubt as resolved