#include <bits/stdc++.h>
using namespace std;
const int N = 1e5 + 5;
long long smen[N];
long long pref[N];
long long add[N];
int v[N];
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  int n;
  cin >> n;
  for (int i = 1; i <= n; i++) {
    cin >> v[i];
  }
  for (int i = 1; i <= n; i++) {
    int x;
    cin >> x;
    pref[i] = pref[i - 1] + x;
  }
  for (int i = 1; i <= n; i++) {
    int lf = i;
    int rg = n;
    int sol = i - 1;
    while (lf <= rg) {
      int md = (lf + rg) >> 1;
      if (pref[md] - pref[i - 1] <= v[i]) {
        sol = md;
        lf = md + 1;
      } else {
        rg = md - 1;
      }
    }
    smen[i]++;
    smen[sol + 1]--;
    add[sol + 1] += v[i] - pref[sol] + pref[i - 1];
  }
  for (int i = 1; i <= n; i++) {
    smen[i] += smen[i - 1];
    cout << smen[i] * (pref[i] - pref[i - 1]) + add[i] << ' ';
  }
  return 0;
}
