#include <bits/stdc++.h>
using namespace std;
int n;
pair<int, int> v[200005], sol[200005];
int main() {
  cin >> n;
  for (int i = 0; i < n; ++i) {
    cin >> v[i].first;
    v[i].second = i;
  }
  sort(v, v + n);
  for (int i = 1; i < n - 1; ++i)
    sol[v[i].second] = {
        min(v[i].first - v[i - 1].first, v[i + 1].first - v[i].first),
        max(v[i].first - v[0].first, v[n - 1].first - v[i].first)};
  sol[v[0].second] = {v[1].first - v[0].first, v[n - 1].first - v[0].first};
  sol[v[n - 1].second] = {v[n - 1].first - v[n - 2].first,
                          v[n - 1].first - v[0].first};
  for (int i = 0; i < n; ++i)
    cout << sol[i].first << ' ' << sol[i].second << '\n';
  return 0;
}
