#include <bits/stdc++.h>
long long a[100010], s[100010];
int main() {
  long long n, x, k, q, b, t;
  scanf("%lld", &x);
  scanf("%lld", &k);
  for (int i = 1; i <= k; i++) {
    scanf("%lld", &a[i]);
    if (i % 2)
      s[i] = s[i - 1] - a[i] + a[i - 1];
    else
      s[i] = s[i - 1] + a[i] - a[i - 1];
  }
  scanf("%lld", &q);
  for (int i = 1; i <= q; i++) {
    scanf("%lld %lld", &t, &b);
    int l = 1, h = k, m, c;
    long long cnt;
    while (l <= h) {
      m = (l + h) / 2;
      if (a[m] >= t)
        h = m - 1;
      else
        l = m + 1;
    }
    c = b + s[l - 1];
    if (c < 0) c = 0;
    if (l % 2)
      cnt = c - t + a[l - 1];
    else
      cnt = c + t - a[l - 1];
    if (cnt < 0) cnt = 0;
    printf("%lld\n", cnt);
  }
  return 0;
}
