#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 10;
long long sum[maxn], v[maxn], ans[maxn], flag[maxn], t[maxn];
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) scanf("%lld", &v[i]);
  for (int i = 1; i <= n; i++) scanf("%lld", &t[i]);
  for (int i = 1; i <= n; i++) sum[i] = sum[i - 1] + t[i];
  for (int i = 1; i <= n; i++) {
    int l = i, r = n;
    while (l <= r) {
      int mid = (l + r) >> 1;
      if (v[i] >= (sum[mid] - sum[i - 1]))
        l = mid + 1;
      else
        r = mid - 1;
    }
    flag[i]++;
    flag[l + 1]--;
    if (v[i] < (sum[l] - sum[i - 1])) ans[l] -= sum[l] - sum[i - 1] - v[i];
  }
  for (int i = 1; i <= n; i++) {
    flag[i] += flag[i - 1];
    ans[i] += t[i] * flag[i];
    if (i == 1)
      printf("%lld", ans[i]);
    else
      printf(" %lld", ans[i]);
  }
  printf("\n");
  return 0;
}
