Given an array of non-negative integers
nums, return the maximum value of nums[i] XOR nums[j] where i != j.Example 1
Input: nums = [10,25,5,3,2,8]
Output: 28
Explanation: Maximum XOR: 25 XOR 5 = 28.
Output: 28
Explanation: Maximum XOR: 25 XOR 5 = 28.
Example 2
Input: nums = [0]
Output: 0
Explanation: Single element — XOR with itself is not possible, answer is 0.
Output: 0
Explanation: Single element — XOR with itself is not possible, answer is 0.