#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, count;
  cin >> n;
  int a[n + 1], b[n + 1];
  for (int i = 0; i < n; i++) {
    cin >> a[i];
  }
  for (int i = 0; i < n; i++) {
    count = 0;
    for (int j = 0; j < n; j++) {
      if (a[i] < a[j]) {
        count++;
      }
    }
    b[i] = 1 + count;
  }
  for (int i = 0; i < n; i++) {
    cout << b[i];
    if (i != (n - 1)) {
      cout << " ";
    }
  }
  cout << endl;
  return 0;
}
