#include <bits/stdc++.h>
using namespace std;
int A[100002];
int Max[100002];
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int N;
  cin >> N;
  for (int i = 1; i <= N; i++) {
    cin >> A[i];
  }
  Max[N] = 0;
  for (int i = N - 1; i > 0; i--) {
    Max[i] = max(A[i + 1], Max[i + 1]);
  }
  for (int i = 1; i <= N; i++) {
    cout << (A[i] > Max[i] ? 0 : Max[i] - A[i] + 1) << ' ';
  }
  return 0;
}
