#include <bits/stdc++.h>
using namespace std;
int n, m, x, a[1000010];
vector<int> v, vv;
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; ++i) {
    scanf("%d", &x);
    a[x] = i;
    v.push_back(x);
    vv.push_back(x);
  }
  for (int i = 1; i < n; ++i) v[i] += v[i - 1];
  scanf("%d", &m);
  while (m--) {
    scanf("%d", &x);
    int i;
    i = lower_bound(v.begin(), v.end(), x) - v.begin();
    printf("%d\n", i + 1);
  }
  return 0;
}
