#include <bits/stdc++.h>
using namespace std;
const double pi = acos(-1.);
const long long mod = 1000000007;
inline void prep() {
  cin.tie(0);
  cin.sync_with_stdio(0);
};
int main() {
  prep();
  int n;
  cin >> n;
  vector<long long> sorted;
  for (int i = 0; i < n; i++) {
    long long num;
    cin >> num;
    sorted.push_back(num);
  }
  sort(sorted.begin(), sorted.end());
  vector<long long> diffs;
  for (int i = 1; i < n; i++) {
    diffs.push_back(sorted[i] - sorted[i - 1]);
  }
  sort(diffs.begin(), diffs.end());
  long long sums[n];
  for (int i = 0; i < diffs.size(); i++) {
    sums[i] = diffs[i];
  }
  for (int i = 1; i < diffs.size(); i++) {
    sums[i] = sums[i] + sums[i - 1];
  }
  int q;
  cin >> q;
  for (int x = 0; x < q; x++) {
    long long l1, r1;
    cin >> l1 >> r1;
    long long len = r1 - l1 + 1;
    int l = 0;
    int r = diffs.size() - 1;
    int mid = (l + r) / 2;
    long long lenbefore = -1;
    while (l <= r) {
      mid = (l + r) / 2;
      if (diffs[mid] < len) {
        l = mid + 1;
        lenbefore = mid;
      } else if (diffs[mid] > len) {
        r = mid - 1;
      } else {
        lenbefore = mid;
        break;
      }
    }
    if (lenbefore == -1) {
      long long res = n * len;
      cout << res << endl;
    } else {
      long long res = n * len;
      res -= (len * (lenbefore + 1)) - sums[lenbefore];
      cout << res << endl;
    }
  }
  return 0;
}
