sir it is giving tle in one case please check
Tricky permutations doubt
@Shivanchal-Agarwal-2530139037020445 yes you need to optimize your solution for removing the TLE. One thing you can do is take setans, instead of vector.
because the operations in set are logn and but count function you were using take O(N) time.
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.