#include <bits/stdc++.h>
using namespace std;
vector<set<int> > st;
int main(void) {
  int n, m, i, j;
  int a, b;
  vector<int> l, r;
  cin >> n >> m;
  for (i = 0; i <= m; i++) {
    set<int> s;
    st.push_back(s);
  }
  for (i = 0; i < n; i++) {
    cin >> a >> b;
    l.push_back(a);
    r.push_back(b);
    for (j = a; j <= b; j++) {
      st[j].insert(i);
    }
  }
  for (i = 1; i <= m; i++) {
    if (i == 1)
      cout << n << endl;
    else {
      set<int> s;
      for (j = 0; j <= m; j += i) {
        for (auto x : st[j]) {
          s.insert(x);
        }
      }
      cout << s.size() << endl;
    }
  }
  return 0;
}
