program main
	implicit none
	integer N, M, i, j
	integer, allocatable :: a(:), b(:), c(:)
	read(*, *) N, M
	allocate(a(1: M))
	allocate(b(1: M))
	allocate(c(1: M))
	do i = 1, M
		read(*, *) a(i), b(i)
	end do
	c(1: M) = 0
	do i = 1, N
		do j = 1, M
			if(a(j) == i) then
				c(i) = c(i) + 1
			end if
			if(b(j) == i) then
				c(i) = c(i) + 1
			end if
		end do
	end do
	do i = 1, N
		write(*, *) c(i)
	end do
end program main