#include <bits/stdc++.h>
using namespace std;
const double PI = acos(-1.0);
const double EPS = 1e-9;
const int MOD = 1e9 + 7;
const int INF = 1e9 + 10000;
const long long INFLL = 4e18;
const int dr[] = {-1, 0, 1, 0, -1, 1, 1, -1};
const int dc[] = {0, 1, 0, -1, 1, 1, -1, -1};
long long v[100005];
long long t[100005];
long long day[100005];
long long sub[100005];
long long pref[100005];
void update(int x, long long val) {
  for (int i = x; i <= 100003; i += (-i & i)) {
    day[i] += val;
  }
}
long long query(int x) {
  long long ret = 0;
  for (int i = x; i > 0; i -= (-i & i)) {
    ret += day[i];
  }
  return ret;
}
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++) cin >> t[i];
  for (int i = 1; i <= n; i++) {
    if (i > 1) {
      pref[i] += pref[i - 1];
    }
    pref[i] += t[i];
  }
  for (int i = 1; i <= n; i++) {
    int idx = lower_bound(pref + 1, pref + 1 + n, v[i] + pref[i - 1]) - pref;
    sub[idx] += (pref[idx] - pref[i - 1]) - v[i];
    update(idx + 1, 1);
  }
  for (int i = 1; i <= n; i++) {
    long long hilang = query(i);
    long long melt = (t[i] * i) - sub[i] - (hilang * t[i]);
    if (i - 1) printf(" ");
    printf("%lld", melt);
  }
  printf("\n");
  return 0;
}
