#include <bits/stdc++.h>
using namespace std;

int main()
{
    int n;
    cin >> n;

    vector<int> a(n);
    for (auto &it : a)
        cin >> it;

    vector<int> rem_pos(n);
    iota(rem_pos.begin(), rem_pos.end(), 0);
    reverse(rem_pos.begin(), rem_pos.end());

    vector<int> where(n);
    for (int i = 0; i < n; i++)
    {
        where[i] = rem_pos[a[i]];
        rem_pos.erase(rem_pos.begin() + a[i]);
    }

    vector<int> p(n);
    for (int i = 0; i < n; i++)
        p[where[i]] = i;

    for (int i = 0; i < n; i++)
        cout << p[i] + 1 << " \n"[i + 1 == n];
}
