#include <bits/stdc++.h>
using namespace std;
int N, a[50010], id[50010], ans[50010];
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cin >> N;
  int i;
  for (i = 0; i < N; i++) {
    cin >> a[i];
    id[i] = i;
  }
  a[N] = a[0];
  sort(id, id + N,
       [](int x, int y) { return a[x] + a[x + 1] < a[y] + a[y + 1]; });
  for (i = 0; i < N; i++) ans[id[i]] = i;
  for (i = 0; i < N; i++) cout << ans[i] << " ";
  cout << "\n";
  return 0;
}
