#include <bits/stdc++.h>
using namespace std;
int cum[100005];
int main() {
  int n, m;
  scanf("%d%d", &n, &m);
  while (n--) {
    int l, r;
    scanf("%d%d", &l, &r);
    for (int i = 1; i <= r;) {
      int f = r / i, la = r / f, cur = max((l - 1) / f + 1, i);
      if (cur <= la) {
        cum[cur]++;
        cum[la + 1]--;
      }
      i = la + 1;
    }
  }
  for (int i = 1; i <= m; i++) {
    cum[i] += cum[i - 1];
    printf("%d\n", cum[i]);
  }
}
