Single Number(2014.2.7)

来源:互联网 发布:大学毕业证制作软件 编辑:程序博客网 时间:2024/06/10 04:31
class Solution {
public:
    int singleNumber(int A[], int n) {
        int x=A[0];
        for(int i=1;i<n;i++){
            x^=A[i];
        }
        return x;
    }
};
0 0
原创粉丝点击