#include <bits/stdc++.h>
struct DOM {
  int id;
  int x;
  int h;
} dom[100010];
int n;
int i, j;
int ans[100010];
bool cmpx(const DOM& A, const DOM& B) { return A.x > B.x; }
int main() {
  scanf("%d", &n);
  for (i = 1; i <= n; i++) ans[dom[i].id = i] = 1;
  for (i = 1; i <= n; i++) scanf("%d%d", &dom[i].x, &dom[i].h);
  std::sort(dom + 1, dom + 1 + n, cmpx);
  for (i = 1; i <= n; i++)
    for (j = i - 1; j && dom[i].x + dom[i].h > dom[j].x; j -= ans[dom[j].id])
      ans[dom[i].id] += ans[dom[j].id];
  for (i = 1; i <= n; i++) printf("%d ", ans[i]);
}
