#include <bits/stdc++.h>
using namespace std;
int main() {
  std::ios_base::sync_with_stdio(0);
  int n, i, k, cnt, a[100005], b[100005] = {0}, d[100005];
  cin >> n;
  for (i = 0; i < n; i++) {
    cin >> a[i];
    b[a[i]]++;
  }
  cnt = 0;
  for (i = 1; i < n + 1; i++) {
    if (b[i] == 0) d[cnt++] = i;
  }
  k = 0;
  for (i = 0; i < n; i++) {
    if (b[a[i]] > 1 || a[i] > n) {
      b[a[i]]--;
      a[i] = d[k];
      k++;
    }
    cout << a[i] << " ";
  }
  return 0;
}
