#include <bits/stdc++.h>
int n, tab[(int)1e5 + 5], ind[(int)1e5 + 5], wyn[(int)1e5 + 5];
int main() {
  int i, j;
  scanf("%d", &n);
  for (i = 0; i < n; i++) {
    scanf("%d", &tab[i]);
    if (tab[i] >= 1 && tab[i] <= n && ind[tab[i]] == 0) {
      ind[tab[i]] = 1;
      wyn[i] = tab[i];
    }
  }
  int iind = 1;
  for (i = 0; i < n; i++) {
    if (wyn[i] == 0) {
      while (ind[iind] == 1) iind++;
      wyn[i] = iind;
      ind[iind] = 1;
      iind++;
    }
  }
  for (i = 0; i < n; i++) printf("%d ", wyn[i]);
  return 0;
}
