import Foundation
var str = readLine()!.components(separatedBy:" ")
var n = [Int]()
for i in str {
    n.append(Int(i)!)
}

var ans = [Int](repeating: 0, count: n[0])

for _ in 1...n[1]{
    str = readLine()!.components(separatedBy:" ")
    for i in str {
        var k = Int(i)!
        ans[k - 1] += 1
    }
}

for i in 0...(n[0] - 1){
    print(ans[i])
}