Given a collection of numbers, nums, that might contain duplicates, return all possible unique permutations in any order.
- An array of integers
nums.
- 1 <= nums.length <= 8
- -10 <= nums[i] <= 10
Input: nums = [1,1,2]
Output: [[1,1,2],[1,2,1],[2,1,1]]