#include <bits/stdc++.h>
using namespace std;
int a[100001], maxi[100001];
int main() {
  int n;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> a[i];
  }
  for (int i = n - 1; i >= 0; i--) {
    maxi[i] = max(maxi[i + 1], a[i]);
  }
  for (int i = 0; i < n; i++) {
    cout << max(maxi[i + 1] - a[i] + 1, 0) << ' ';
  }
}
