NOTE: Try doing it without using SET or MAP!

Any hint ?

May i use vector sorting technique

just use a set<vector> and find all permutations using backtracking and store in it… it will store only unique ans

1 Like

Getting TLE in last test why ?

Hi… there is no code saved at this link

ur code seems fine and should have passed… u can once try this method https://ide.codingblocks.com/s/589607 here instead of int array i am taking strings as input and finding unique permutations of the same

3
3 1 1
The given code
Not printing all permutation ??

image
it is printing

1 Like

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.