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