#include <bits/stdc++.h>
using namespace std;
int v[100005];
long long int t[100005];
int ans[100005] = {0};
map<int, long long int> mp;
int main() {
  int n;
  scanf("%d", &n);
  for (int i = 1; i <= n; ++i) {
    scanf("%d", &v[i]);
  }
  t[0] = 0;
  for (int i = 1; i <= n; ++i) {
    scanf("%d", &t[i]);
    t[i] += t[i - 1];
  }
  for (int i = 1; i <= n; ++i) {
    int in = lower_bound(t + 1, t + n + 1, v[i] + t[i - 1]) - t;
    ans[i]++;
    ans[in]--;
    mp[in] += (v[i] - (t[in - 1] - t[i - 1]));
  }
  int cur = 0;
  for (int i = 1; i <= n; ++i) {
    cur += ans[i];
    long long int sum = (1LL * cur * (t[i] - t[i - 1]));
    sum += mp[i];
    printf("%lld ", sum);
  }
  printf("\n");
}
