Problem Description
If there are multiple (X, Y); choose one with the smallest X.
A = 1
Input 2:
A = 2
[1, 1]
Output 2:
[1, 2]
there is only one possible pair to choose, (1,1)
Explanation 2:
There are four options: (1,1), (1,2), (2,1), (2,2). (1,1) and (2,2) have xor 0 whereas (1,2) and (2,1) have xor 3.
We chose (1,2) since it has smaller x.
NOTE: You only need to implement the given function. Do not read input, instead use the arguments to the function. Do not print the output, instead return values as specified. Still have a question? Checkout Sample Codes for more details.