Permutations
Medium
Recursion & Backtracking
Given an array of distinct integers, print all permutations in lexicographic order of the index sequence (the order produced by choosing the earliest unused element first).
Constraints
1 <= n <= 6
Discussion
No discussions yet.
Shalyam Support
Hi! Ask us anything — we'll reply on WhatsApp or Telegram within 24 hours.