#include <bits/stdc++.h>
using namespace std;
const int N = 100005;
int h[N], ans[N];
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 1; i <= n; ++i) {
    scanf("%d", h + i);
  }
  for (int mx = 0, i = n; i >= 1; --i) {
    if (mx >= h[i]) ans[i] = mx - h[i] + 1;
    mx = max(mx, h[i]);
  }
  for (int i = 1; i <= n; ++i) {
    printf("%d ", ans[i]);
  }
  return 0;
}
