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