#include <bits/stdc++.h>
struct students {
  int a;
};
int main() {
  int n, i, j;
  scanf("%d", &n);
  int count[n];
  for (i = 0; i < n; i++) count[i] = 0;
  struct students student[n];
  for (i = 0; i < n; i++) scanf("%d", &student[i].a);
  for (i = 0; i < n; i++) {
    for (j = 0; j < n; j++) {
      if (student[j].a > student[i].a) count[i]++;
    }
  }
  for (i = 0; i < n; i++) {
    student[i].a = 1 + count[i];
    printf("%d ", student[i].a);
  }
}
