object Main {
  def main(args: Array[String]) {
    val List(n,m) = scala.io.StdIn.readLine().split(' ').map(_.toInt).toList
    val intervals = for(i <- Range(0,n).toArray) yield {
      val List(l,r) = scala.io.StdIn.readLine().split(' ').map(_.toInt).toList
      Array((r-l+1), l, r)
    }
    var sortedInt = intervals.sortBy(_.apply(0))
    val station = new Array[Int](m+2)

    for(d <- 1 to m) {
      var count = 0
      val (before, after) = sortedInt.span(_.apply(0) < d)
      for (int <- before) {
        station(int(1)) += 1
        station(int(2)+1) -= 1
      }
      val cumulative = station.scanLeft(0)((x,y) => x+y).tail
      for(i <- Range(0, m+1, d)) count += cumulative(i)
      count += after.length
      sortedInt = after
      println(count)
    }
  }
}
