#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1e9 + 7;
const double PI = 2 * acos(0.0);
pair<long long, long long> arrR[100005];
long long arr[100005];
int main() {
  long long n, fi = 0;
  cin >> n;
  for (int i = 0; i < n; i++) {
    cin >> arr[i];
  }
  arrR[n - 1].first = arr[n - 1];
  for (int i = n - 2; i >= 0; i--) {
    if (arrR[i + 1].first == arr[i]) {
      arrR[i].second = -1;
    }
    arrR[i].first = max(arrR[i + 1].first, arr[i]);
  }
  for (int i = 0; i < n; i++) {
    if (arrR[i].first == arr[i]) {
      if (arrR[i].second == -1)
        cout << arrR[i].first + 1 - arr[i] << " ";
      else
        cout << 0 << " ";
    } else
      cout << arrR[i].first + 1 - arr[i] << " ";
  }
}
