#include <bits/stdc++.h>
using namespace std;
long long n, m, a[(int)1e6], s[(int)1e6], x;
long long ans() {
  long long st = 0, en = n - 1;
  while (st < en) {
    long long mid = (st + en) >> 1;
    if (s[mid] >= x)
      en = mid;
    else
      st = mid + 1;
  }
  return st;
}
int main() {
  scanf("%I64d", &n);
  for (int i = 0; i < n; i++) scanf("%I64d", a + i);
  scanf("%I64d", &m);
  s[0] = a[0];
  for (int i = 1; i < n; i++) s[i] = s[i - 1] + a[i];
  while (m--) {
    scanf("%I64d", &x);
    cout << ans() + 1 << '\n';
  }
  return 0;
}
