You are given a list nums of size n. Each number in nums lies from 1 to n.
Each integer appears exactly once, except x which appears twice, and y which doesn't appear at all.
Find x and y. Return them as an array [x, y].
nums: [3, 2, 1, 2]
Answer: [2, 4]
The first line contains an integer âTâ denoting the number of test cases.
For each test case, the input has two lines:
For each test case, the output has one line containing two space-separated integers x and y.
2
4
3 2 1 2
5
5 3 2 4 3
2 4
3 1
1 <= T <= 100
1 <= n <= 1000