#include <bits/stdc++.h>
using namespace std;
template <class T, class U>
ostream& operator<<(ostream& o, const pair<T, U>& p) {
  o << "(" << p.first << "," << p.second << ")";
  return o;
}
template <class T>
ostream& operator<<(ostream& o, const vector<T>& v) {
  o << "[";
  for (T t : v) {
    o << t << ",";
  }
  o << "]";
  return o;
}
int main() {
  int n, m;
  cin >> n >> m;
  vector<int> l(n), r(n);
  for (int i = (int)(0); i < (int)(n); i++) cin >> l[i] >> r[i];
  vector<int> vec(m + 2, 0);
  for (int i = (int)(0); i < (int)(n); i++) {
    int k = 1;
    int d = r[i] - l[i] + 1;
    int ll = min(l[i], m + 1);
    int rr = min(r[i], m + 1);
    while (true) {
      vec[ll]++;
      vec[rr + 1]--;
      k++;
      if (d >= ll) break;
      rr = min(r[i] / k, ll - 1);
      ll = (l[i] + k - 1) / k;
    }
    k--;
    ll = (l[i] + k - 1) / k;
    vec[1]++;
    vec[min(d, ll - 1) + 1]--;
  }
  for (int i = (int)(0); i < (int)(m); i++) {
    vec[i + 1] += vec[i];
    printf("%d\n", vec[i + 1]);
  }
  return 0;
}
