#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e5 + 10;
long long m, n, a[maxn], b[maxn], x, y, q, ans, sum1[maxn], c[maxn], aa[maxn],
    e[maxn], sum2[maxn], d[maxn];
int main() {
  cin >> n;
  for (int i = 1; i <= n; i++) scanf("%I64d", a + i), aa[i] = a[i];
  for (int i = 1; i <= n; i++) scanf("%I64d", b + i);
  for (int i = 1; i <= n; i++) d[i] = i;
  for (int i = 1; i <= n; i++) {
    sum1[i] += sum1[i - 1] + b[i];
  }
  long long t = 0;
  for (int i = 1; i <= n; i++) {
    aa[i] += t;
    c[i] = lower_bound(sum1 + i, sum1 + n + 1, aa[i]) - sum1;
    sum2[c[i]] += a[i] - (sum1[c[i] - 1] - sum1[i - 1]);
    t += b[i];
    e[c[i]]++;
  }
  for (int i = 1; i <= n; i++) e[i] += e[i - 1];
  for (int i = 1; i <= n; i++) {
    d[i] -= e[i];
  }
  long long ans = 0;
  for (int i = 1; i <= n; i++) {
    printf("%I64d ", sum2[i] + d[i] * b[i]);
  }
  return 0;
}
