#include <bits/stdc++.h>
using namespace std;
const long long N = 1e5 + 5;
const long long mod = 1e9 + 7;
long long powermodm(long long x, long long n, long long M) {
  long long result = 1;
  while (n > 0) {
    if (n % 2 == 1) result = (result * x) % M;
    x = (x * x) % M;
    n = n / 2;
  }
  return result;
}
long long power(long long _a, long long _b) {
  long long _r = 1;
  while (_b) {
    if (_b % 2 == 1) _r = (_r * _a);
    _b /= 2;
    _a = (_a * _a);
  }
  return _r;
}
long long gcd(long long a, long long b) {
  if (a == 0) return b;
  return gcd(b % a, a);
}
long long lcm(long long a, long long b) {
  return (max(a, b) / gcd(a, b)) * min(a, b);
}
int32_t main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long n, x;
  cin >> n;
  vector<long long> a;
  set<long long> s;
  for (long long i = 0; i < n; i++) {
    cin >> x;
    s.insert(x);
  }
  for (auto it = s.begin(); it != s.end(); it++) a.push_back(*it);
  n = a.size();
  long long arr[n];
  vector<long long> pre(n - 1), v(n - 1);
  for (long long i = 0; i < n - 1; i++) {
    arr[i] = a[i + 1] - a[i];
    v[i] = arr[i];
  }
  sort(v.begin(), v.end());
  for (long long i = 0; i < n - 1; i++) pre[i] = v[i];
  for (long long i = 1; i < n - 1; i++) pre[i] += pre[i - 1];
  long long q;
  cin >> q;
  while (q--) {
    long long l, r;
    cin >> l >> r;
    long long sum = 0;
    long long val = r - l;
    long long x = 0, y = n - 2, ind = n - 1;
    while (x <= y) {
      long long mid = (x + y) >> 1;
      if (v[mid] <= val) {
        x = mid + 1;
      } else {
        y = mid - 1;
        ind = min(ind, mid);
      }
    }
    long long add = 0, ext = 0;
    if (ind != 0) add = pre[ind - 1];
    if (ind != n - 1) ext = ((n - ind - 1) * (r - l + 1));
    long long ans = add + ext;
    cout << ans + (r - l + 1) << " ";
  }
  return 0;
}
