i am not able to pass all the test cases.4/5 are passed.Only 1 is not able to pass and i don’t why.
Next Permutation Problem
@S18LP0113
no need for extra b array or any other logic.
just call next permutation and thenprint the resultant array.
what about the case when no next permutation exists…?
function will handle that as well ,it will give u smallest permution in that case
Thanks a lot
for your help