#include <bits/stdc++.h>
using namespace std;
vector<long long> v, dif;
long long n, a, b;
long long pref[100005];
int main() {
  scanf("%lld", &n);
  for (int i = 1; n >= i; ++i) {
    scanf("%lld", &a);
    v.push_back(a);
  }
  sort(v.begin(), v.end());
  for (int i = 1; (int)v.size() > i; ++i) dif.push_back(v[i] - v[i - 1]);
  sort(dif.begin(), dif.end());
  for (int i = 0; (int)dif.size() > i; ++i)
    pref[i] = (i > 0 ? pref[i - 1] : 0) + dif[i];
  pref[(int)dif.size()] = pref[(int)dif.size() - 1];
  int q;
  scanf("%d", &q);
  while (q--) {
    scanf("%lld %lld", &a, &b);
    long long len = b - a + 1;
    long long ans = 0;
    int e = upper_bound(dif.begin(), dif.end(), len - 1) - dif.begin();
    if (e - 1 >= 0) ans += pref[e - 1];
    printf("%lld\n", ans + max(1LL * 0, (n - e) * len));
  }
  return 0;
}
