#include <bits/stdc++.h>
using namespace std;
int n, i, a[100001], b[100001], ans;
int sum1 = 0;
int sum2 = 0;
int main() {
  cin >> n;
  for (i = 1; i <= n - 1; i++) {
    cin >> a[i];
    sum1 += a[i];
  }
  for (i = 1; i <= n; i++) {
    b[i] = i;
    sum2 += b[i];
  }
  ans = sum2 - sum1;
  cout << ans;
}
