#include <bits/stdc++.h>
using namespace std;
int main() {
  int n;
  cin >> n;
  map<int, int> cnt;
  for (int i = 0; i < n * n; ++i) {
    int x;
    cin >> x;
    cnt[x]++;
  }
  vector<int> arr;
  for (map<int, int>::iterator e = cnt.begin(); e != cnt.end(); ++e) {
    if (e->second % 2 == 1) arr.push_back(e->first);
  }
  for (int i = 0; i < arr.size(); ++i) {
    cout << arr[i] << " ";
  }
  cout << endl;
  return 0;
}
