fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. long long n, res;
  6. while (cin >> n)
  7. res ^= n;
  8. cout << res;
  9. return 0;
  10. }
Success #stdin #stdout 0s 15232KB
stdin
1 2 3 1 2 3 1  2 3 1 2 3 1
stdout
1