#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, i, a[100099];
  cin >> n;
  for (i = 0; i < n; i++) {
    cin >> a[i];
  }
  sort(a, a + n);
  cout << abs(a[0] - a[1]) << " ";
  cout << abs(a[n - 1] - a[0]) << endl;
  for (i = 1; i < n - 1; i++) {
    cout << min(abs(a[i + 1] - a[i]), abs(a[i - 1] - a[i]));
    cout << " ";
    cout << max(abs(a[n - 1] - a[i]), abs(a[0] - a[i]));
    cout << endl;
  }
  cout << abs(a[n - 1] - a[n - 2]) << " ";
  cout << abs(a[0] - a[n - 1]) << endl;
  return 0;
}
