#include <bits/stdc++.h>
using namespace std;
struct shu {
  int z, bh;
} b[50005];
int a[50005];
bool cmp(shu x, shu y) { return x.z > y.z; }
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  for (int i = 1; i < n; i++) b[i].bh = i, b[i].z = n - a[i] - a[i + 1];
  b[n].bh = n;
  b[n].z = n - a[1] - a[n];
  sort(b + 1, b + n + 1, cmp);
  for (int i = 1; i <= n; i++) a[b[i].bh] = i;
  for (int i = 1; i <= n; i++) printf("%d ", a[i] - 1);
}
