#include <bits/stdc++.h>
using namespace std;
int n, m, kq, ct;
pair<int, int> a[300005];
inline int read() {
  int s = 0, t = 1;
  char c = getchar();
  while (!isdigit(c)) {
    if (c == '-') t = -1;
    c = getchar();
  }
  while (isdigit(c)) s = s * 10 + c - 48, c = getchar();
  return s * t;
}
inline void Write(int x) {
  if (x > 9) Write(x / 10);
  putchar(x % 10 + 48);
}
int main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  n = read();
  m = read();
  for (int i = 1; i <= n; ++i) {
    a[i].first = read();
    a[i].second = read();
  }
  sort(a + 1, a + n + 1);
  for (int i = 1; i <= m; ++i) {
    ct = 1;
    kq = 0;
    for (int j = i; j <= m; j += i) {
      while (ct <= n && a[ct].first <= j) {
        if (a[ct].second >= j) kq++;
        ct++;
      }
    }
    Write(kq);
    putchar('\n');
  }
  return 0;
}
