Why is the brute-force approach less ideal here?
Practice this question from Combination Sum - Reuse Choice Backtracking Pattern Practice Quiz, with options and an explanation.
Question
Why is the brute-force approach less ideal here?
Option A — Correct answer
Trying every ordered sequence creates duplicate permutations.
Option B
It always avoids invalid states
Option C
It uses no recursion
Option D
It only works for sorted arrays
Explanation
Trying every ordered sequence creates duplicate permutations.