4 Sum - Target Sum With Unique Quadruple
medium
1. Given an array nums of 'n' integers. 2. You have to return an array of all the unique quadruple [nums[a], nums[b], nums[c], nums[d]] such that: 2.1 a, b, c, and d are less than 'n' and greater than 0 2.2 a,. b, c, and d are Unique. 2.3 nums[a] + nums[b] + nums[c] + nums[d] == target. 3. You can return answer in any order.
Constraints
1. 1 <= nums.length <= 200 2. -10^9 <= nums[i] <= 10^9 3. -10^9 <= target <= 10^9
Format
Input
Input is managed for you.
Output
Output is managed for you.
Example
Sample Input
6
1 0 -1 0 -2 2
0
Sample Output
-1 0 0 1
-2 -1 1 2
-2 0 0 2