#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  ;
  long long n, i, j, tmp1, tmp2;
  vector<long long> v1, v2;
  long long mx, mn;
  cin >> n;
  long long arr[n];
  for (i = 0; i < n; i++) cin >> arr[i];
  tmp1 = abs(arr[0] - arr[1]);
  v1.push_back(tmp1);
  for (i = 1; i < n - 1; i++) {
    tmp1 = abs(arr[i] - arr[i - 1]);
    tmp2 = abs(arr[i] - arr[i + 1]);
    v1.push_back(min(tmp1, tmp2));
  }
  tmp1 = abs(arr[n - 1] - arr[n - 2]);
  v1.push_back(tmp1);
  for (i = 0; i < n; i++) {
    tmp1 = abs(arr[i] - arr[0]);
    tmp2 = abs(arr[i] - arr[n - 1]);
    v2.push_back(max(tmp1, tmp2));
  }
  for (i = 0; i < n; i++) cout << v1[i] << ' ' << v2[i] << '\n';
  return 0;
}
