#include <bits/stdc++.h>
using namespace std;
const int MaxN = 1e5;
int n;
bool flag;
int a[MaxN + 5], b[MaxN + 5];
int Max = 1 >> 30;
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%d", &a[i]);
  for (int i = n; i >= 1; i--) {
    flag = 0;
    if (a[i] > Max) {
      Max = a[i];
      flag = 1;
    }
    b[i] = Max - a[i] + 1;
    if (flag) b[i]--;
  }
  for (int i = 1; i <= n; i++) printf("%d ", b[i]);
  printf("\n");
}
