Given two positive integers num1 and num2, find an integer x such that:
x has the same number of set bits (num2.
The value of x $ ext{XOR}$ num1 is minimized.
Return the integer x.
Constraints:
num1, num2
Given two positive integers num1 and num2, find an integer x such that:
x has the same number of set bits (num2.
The value of x $ ext{XOR}$ num1 is minimized.
Return the integer x.
Constraints:
num1, num2