#include <bits/stdc++.h>
using namespace std;
template <class G>
class Fenwick_tree_dual {
  vector<G> a;

 public:
  Fenwick_tree_dual(int n) : a(n) {}
  void add(int l, int r, G val) {
    if (l == 0) {
      for (r--; r >= 0; r = (r & (r + 1)) - 1) a[r] += val;
      return;
    }
    add(0, r, val);
    add(0, l, -val);
  }
  G sum(int i) {
    G res{};
    for (; i < a.size(); i |= i + 1) res += a[i];
    return res;
  }
};
struct interval {
  int l, r;
  bool operator<(const interval& I) const { return r - l < I.r - I.l; }
};
int main() {
  int n, m;
  cin >> n >> m;
  interval I[100];
  for (int i = 0; i < (n); i++) cin >> I[i].l >> I[i].r, I[i].r++;
  sort(I, I + n);
  int idx = 0;
  Fenwick_tree_dual<int> F(m + 1);
  for (int d = 1; d <= m; d++) {
    while (idx < n && I[idx].r - I[idx].l <= d) {
      F.add(I[idx].l, I[idx].r, 1);
      idx++;
    }
    int ans = n - idx;
    for (int x = d; x <= m; x += d) ans += F.sum(x);
    cout << ans << '\n';
  }
  return 0;
}
