#include <bits/stdc++.h>
using namespace std;
map<long long int, long long int> m;
int main() {
  long long int i, n, d, j;
  cin >> n;
  long long int a[n];
  for (i = 1; i <= n; i++) {
    cin >> a[i];
    m[a[i]]++;
  }
  j = 1;
  for (i = 1; i <= n; i++) {
    if (a[i] > n || m[a[i]] > 1) {
      while (m[j] > 0) j++;
      m[j]++;
      m[a[i]]--;
      a[i] = j;
    }
  }
  for (i = 1; i <= n; i++) {
    cout << a[i] << " ";
  }
  return 0;
}
