#include <bits/stdc++.h>
int main(void) {
  int N, M;
  std::cin >> N >> M;
  std::vector<std::pair<int, int>> a;
  a.reserve(N);
  for (int i = 0; i < N; i++) {
    int l, r;
    std::cin >> l >> r;
    a.emplace_back(std::make_pair(l, r));
  }
  for (int d = 1; d <= M; d++) {
    int num = 0;
    for (auto p : a) {
      int l, r;
      std::tie(l, r) = p;
      if (l / d != r / d || l % d == 0 || r % d == 0) {
        num++;
      }
    }
    std::cout << num << std::endl;
  }
  return 0;
}
