#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(nullptr);
  cout.tie(nullptr);
  int T = 1;
  for (int t = 1; t <= T; ++t) {
    int n;
    cin >> n;
    int input[n + 1];
    map<int, bool> yes;
    for (int i = 1; i <= n; ++i) {
      cin >> input[i];
      if (input[i] > n) {
        input[i] = -1;
      } else {
        if (yes[input[i]]) {
          input[i] = -1;
        }
      }
      yes[input[i]] = true;
    }
    int idx = 1;
    for (int i = 1; i <= n; ++i) {
      if (input[i] == -1) {
        while (yes[idx]) {
          idx += 1;
        }
        yes[idx] = true;
        input[i] = idx;
      }
    }
    for (int i = 1; i <= n; ++i) {
      cout << input[i] << " ";
    }
  }
}
