#include <bits/stdc++.h>
using namespace std;
int n, m;
int l[300000], r[300000];
int main() {
  cin >> n >> m;
  for (int i = 0; i < n; i++) cin >> l[i] >> r[i];
  for (int i = 0; i < m; i++) {
    int cnt = 0;
    for (int j = 0; j < n; j++) {
      if ((r[j] / (i + 1) - (l[j] - 1) / (i + 1)) > 0) {
        cnt += 1;
      }
    }
    cout << cnt << endl;
  }
  return 0;
}
