147 在其它数出现次数都为偶数的数组中找到出现次数为奇数次的数
Table of Contents

ac

import java.io.BufferedReader;
import java.io.InputStreamReader;
import java.util.*;

public class Main {
    public static Scanner sc = new Scanner(System.in);

    public static BufferedReader reader = new BufferedReader(new InputStreamReader(System.in));

    public static long mod = (long)Math.pow(2,29);

    public static void main(String[] args) throws Exception {
        int n = sc.nextInt();
        int ans = 0;
        for(int i=0;i<n;i++){
            int val = sc.nextInt();
            ans = ans ^ val;
        }
        System.out.println(ans);
    }

}
/*
异或处理

5
3 1 3 1 2
2

3
6 6 3
3
*/