#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1e9 + 7;
const long long INF = 1e18;
int main() {
  cin.tie(0);
  ios::sync_with_stdio(false);
  long long n, m;
  cin >> n >> m;
  int ans[m + 1];
  memset(ans, 0, sizeof(ans));
  int cum[m + 1];
  memset(cum, 0, sizeof(cum));
  for (long long i = (0); i < (n); i++) {
    long long l, r;
    cin >> l >> r;
    for (long long j = 1; j * j <= m; j++) {
      long long rj = r / j;
      long long lj = (l - 1) / j;
      if (lj < rj) {
        ans[j]++;
      }
      cum[rj]++;
      cum[lj]--;
    }
  }
  for (long long j = (m); j >= (1); j--) {
    cum[j - 1] += cum[j];
  }
  for (long long j = (1); j <= (m); j++) {
    cout << ((j * j <= m) ? ans[j] : cum[j]) << endl;
  }
  return 0;
}
