This theory is part of Premium
The full write-up (worked counting examples, the trap list and the interview playbook) unlocks with a Premium plan, along with every Pro visualizer.
See pricingFind the kth permutation in order without generating the whole list.
What this asks
Find the kth permutation in order without generating the whole list.
Pick each digit by dividing k by the factorial of the remaining count, then continue with the remainder.
The full write-up (worked counting examples, the trap list and the interview playbook) unlocks with a Premium plan, along with every Pro visualizer.
See pricing