line = function()
	local t = {}
	string.gsub(io.read(),"(%S+)", function (v) table.insert(t,tonumber(v)) end)
	return t[1], t[2]
end

N, M = line()

ans = {}

for i=1, N do
	ans[i] = 0	
end

for i = 1, M do
	a, b = line()
	ans[a] = ans[a] + 1
	ans[b] = ans[b] + 1
end

for i = 1, N do
	print(ans[i])	
end