object Main extends App {
  val Array(n,m) = readLine.split(" ").map{_.toInt}
  val (a,b) = (1 to m).map{_ =>
    val Array(x,y) = readLine.split(" ").map{_.toInt}
  	(x,y)}.unzip
  
  (1 to n).foreach{i => println(a.count{_ == i} + b.count{_ == i})}
}