class Solution { public: int singleNumber(int A[], int n) { int rlt=0; for(int i=0;i<n;i++) { rlt = rlt ^ A[i]; } return rlt; } };