#include <bits/stdc++.h>
using namespace std;
long long binary(long long a[], long long l, long long r, long long x) {
  long long mid, ans = -1;
  while (r >= l) {
    mid = (l + r) / 2;
    if (x <= a[mid]) {
      ans = mid;
      r = mid - 1;
    } else
      l = mid + 1;
  }
  return ans;
}
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long n, m;
  cin >> n;
  long long a[n];
  for (long long i = 0; i < n; i++) cin >> a[i];
  cin >> m;
  long long b[m];
  for (long long i = 0; i < m; i++) cin >> b[i];
  for (long long i = 1; i < n; i++) a[i] += a[i - 1];
  for (long long i = 0; i < m; i++) {
    long long x = binary(a, 0, n - 1, b[i]);
    cout << x + 1 << '\n';
  }
}
