#include <bits/stdc++.h>
using namespace std;
const int nn = 100005;
string s, ans;
int main() {
  int n, arr[1000000];
  cin >> n;
  for (int i = 1; i <= n; ++i) {
    scanf("%lld", &arr[i]);
  }
  for (int i = 1; i <= n; ++i) {
    long long m1 = abs(arr[i] - arr[i + 1]);
    long long m2 = abs(arr[i] - arr[i - 1]);
    long long ans1 = min(m1, m2);
    if (i == 1) ans1 = m1;
    if (i == n) ans1 = m2;
    printf("%lld ", ans1);
    long long m3 = abs(arr[i] - arr[1]);
    long long m4 = abs(arr[i] - arr[n]);
    long long ans2 = max(m3, m4);
    if (i == n) ans2 = m3;
    if (i == 1) ans2 = m4;
    printf("%lld\n", ans2);
  }
  return 0;
}
