#include <bits/stdc++.h>
using namespace std;
int a[100005];
int b[100005];
int c[100005];
int main() {
  int t, n, i;
  while (scanf("%d", &n) != EOF) {
    memset(a, 0, sizeof(a));
    memset(b, 0, sizeof(b));
    memset(c, 0, sizeof(c));
    for (i = 1; i <= n; i++) {
      cin >> a[i];
      if (b[a[i]] == 0 && a[i] <= n) {
        b[a[i]] = 1;
      } else
        c[i] = 1;
    }
    t = 1;
    for (i = 1; i <= n; i++) {
      if (c[i] == 1) {
        while (b[t]) t++;
        a[i] = t;
        b[t] = 1;
      }
    }
    for (i = 1; i < n; i++) {
      cout << a[i] << " ";
    }
    cout << a[n] << endl;
  }
  return 0;
}
