#include <bits/stdc++.h>
const int BITS = 31;
using namespace std;
const int N = 100005;
int n;
long long dem[N], inc[N], v[N], t[N], sums[N];
int lowest, highest, mid, curr;
int main() {
  cin >> n;
  int i;
  for (i = 1; i <= n; i++) {
    cin >> v[i];
  }
  for (i = 1; i <= n; i++) {
    cin >> t[i];
  }
  for (i = 1; i <= n; i++) {
    sums[i] = sums[i - 1] + t[i];
  }
  for (i = 1; i <= n; i++) {
    lowest = i;
    highest = n;
    curr = i - 1;
    while (highest >= lowest) {
      mid = (lowest + highest) >> 1;
      if (sums[mid] - sums[i - 1] <= v[i]) {
        curr = mid;
        lowest = mid + 1;
      } else
        highest = mid - 1;
    }
    if (curr >= i) {
      dem[i] += 1;
      dem[curr + 1] -= 1;
    }
    inc[curr + 1] = inc[curr + 1] + v[i] - (sums[curr] - sums[i - 1]);
  }
  for (i = 1; i <= n; i++) {
    dem[i] = dem[i] + dem[i - 1];
    cout << dem[i] * t[i] + inc[i] << " ";
  }
  return 0;
}
