Home => ProblemSet => 4.1-02:最大异或对
Problem1268--4.1-02:最大异或对

1268: 4.1-02:最大异或对

Time Limit: 1 Sec  Memory Limit: 128 MB  Submit: 0  Solved: 2
[ Submit ] [ Status ] [ Creator: ][ 参考程序 ]

Description

在给定的N个整数A1,A2……AN中选出两个进行xor(异或)运算,得到的结果最大是多少?

Input

第一行输入一个整数N。
第二行输入N个整数A1~An。

Output

输出一个整数表示答案。

Sample Input Copy

3
1 2 3

Sample Output Copy

3

HINT

1≤N≤10^5,
0≤Ai<2^31

Source/Category