#include <bits/stdc++.h>
const int maxn = 1e5 + 10;
int N;
int V[maxn], T[maxn];
long long S[maxn], E[maxn], D[maxn], X[maxn];
int main() {
  scanf("%d", &N);
  for (int i = 1; i <= N; i++) scanf("%d", &V[i]);
  for (int i = 1; i <= N; i++) scanf("%d", &T[i]);
  for (int i = 1; i <= N; i++) S[i] = S[i - 1] + T[i];
  for (int i = 1; i <= N; i++) {
    int l = i, r = N;
    while (l <= r) {
      int m = (l + r) >> 1;
      if (V[i] >= S[m] - S[i - 1])
        l = m + 1;
      else
        r = m - 1;
    }
    E[i]++;
    E[l]--;
    D[l] += V[i] - (S[l - 1] - S[i - 1]);
  }
  for (int i = 1; i <= N; i++) X[i] = X[i - 1] + E[i];
  for (int i = 1; i <= N; i++) printf("%lld ", X[i] * T[i] + D[i]);
  return 0;
}
