import java.io.File;
import java.io.IOException;
import java.util.ArrayDeque;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Comparator;
import java.util.Deque;
import java.util.List;
import java.util.Scanner;

public class Main {
 
	public static void main(String[] args) throws IOException {
		//File file = new File("input.txt");
		//Scanner in = new Scanner(file);
		
		Scanner in = new Scanner(System.in);
		
		int N = in.nextInt();
		int M = in.nextInt();
		int[][] edge = new int[N+1][N+1];
		for(int i = 0; i < M; i++){
			int a = in.nextInt();
			int b = in.nextInt();
			edge[a][b]++;
			edge[b][a]++;
		}
		
		for(int i = 1; i <= N; i++){
			int sum = 0;
			for(int j = 1; j <= N; j++) sum += edge[i][j];
			System.out.println(sum);
		}
	}
} import java.io.File; File java.io import java.io.IOException; IOException java.io import java.util.ArrayDeque; ArrayDeque java.util import java.util.ArrayList; ArrayList java.util import java.util.Arrays; Arrays java.util import java.util.Comparator; Comparator java.util import java.util.Deque; Deque java.util import java.util.List; List java.util import java.util.Scanner; Scanner java.util public class Main {
 
	public static void main(String[] args) throws IOException {
		//File file = new File("input.txt");
		//Scanner in = new Scanner(file);
		
		Scanner in = new Scanner(System.in);
		
		int N = in.nextInt();
		int M = in.nextInt();
		int[][] edge = new int[N+1][N+1];
		for(int i = 0; i < M; i++){
			int a = in.nextInt();
			int b = in.nextInt();
			edge[a][b]++;
			edge[b][a]++;
		}
		
		for(int i = 1; i <= N; i++){
			int sum = 0;
			for(int j = 1; j <= N; j++) sum += edge[i][j];
			System.out.println(sum);
		}
	}
} Main public static void main(String[] args) throws IOException {
		//File file = new File("input.txt");
		//Scanner in = new Scanner(file);
		
		Scanner in = new Scanner(System.in);
		
		int N = in.nextInt();
		int M = in.nextInt();
		int[][] edge = new int[N+1][N+1];
		for(int i = 0; i < M; i++){
			int a = in.nextInt();
			int b = in.nextInt();
			edge[a][b]++;
			edge[b][a]++;
		}
		
		for(int i = 1; i <= N; i++){
			int sum = 0;
			for(int j = 1; j <= N; j++) sum += edge[i][j];
			System.out.println(sum);
		}
	} main {
		//File file = new File("input.txt");
		//Scanner in = new Scanner(file);
		
		Scanner in = new Scanner(System.in);
		
		int N = in.nextInt();
		int M = in.nextInt();
		int[][] edge = new int[N+1][N+1];
		for(int i = 0; i < M; i++){
			int a = in.nextInt();
			int b = in.nextInt();
			edge[a][b]++;
			edge[b][a]++;
		}
		
		for(int i = 1; i <= N; i++){
			int sum = 0;
			for(int j = 1; j <= N; j++) sum += edge[i][j];
			System.out.println(sum);
		}
	} Scanner in = new Scanner(System.in); in new Scanner(System.in) int N = in.nextInt(); N in.nextInt() in.nextInt in int M = in.nextInt(); M in.nextInt() in.nextInt in int[][] edge = new int[N+1][N+1]; edge new int[N+1][N+1] N+1 N 1 N+1 N 1 for(int i = 0; i < M; i++){
			int a = in.nextInt();
			int b = in.nextInt();
			edge[a][b]++;
			edge[b][a]++;
		} int i = 0; int i = 0; i 0 i < M i M i++ i++ i {
			int a = in.nextInt();
			int b = in.nextInt();
			edge[a][b]++;
			edge[b][a]++;
		} {
			int a = in.nextInt();
			int b = in.nextInt();
			edge[a][b]++;
			edge[b][a]++;
		} int a = in.nextInt(); a in.nextInt() in.nextInt in int b = in.nextInt(); b in.nextInt() in.nextInt in edge[a][b]++ edge[a][b] edge[a] edge a b edge[b][a]++ edge[b][a] edge[b] edge b a for(int i = 1; i <= N; i++){
			int sum = 0;
			for(int j = 1; j <= N; j++) sum += edge[i][j];
			System.out.println(sum);
		} int i = 1; int i = 1; i 1 i <= N i N i++ i++ i {
			int sum = 0;
			for(int j = 1; j <= N; j++) sum += edge[i][j];
			System.out.println(sum);
		} {
			int sum = 0;
			for(int j = 1; j <= N; j++) sum += edge[i][j];
			System.out.println(sum);
		} int sum = 0; sum 0 for(int j = 1; j <= N; j++) sum += edge[i][j]; int j = 1; int j = 1; j 1 j <= N j N j++ j++ j sum += edge[i][j]; sum += edge[i][j] sum edge[i][j] edge[i] edge i j System.out.println(sum) System.out.println System.out System System.out sum String[] args args public class Main {
 
	public static void main(String[] args) throws IOException {
		//File file = new File("input.txt");
		//Scanner in = new Scanner(file);
		
		Scanner in = new Scanner(System.in);
		
		int N = in.nextInt();
		int M = in.nextInt();
		int[][] edge = new int[N+1][N+1];
		for(int i = 0; i < M; i++){
			int a = in.nextInt();
			int b = in.nextInt();
			edge[a][b]++;
			edge[b][a]++;
		}
		
		for(int i = 1; i <= N; i++){
			int sum = 0;
			for(int j = 1; j <= N; j++) sum += edge[i][j];
			System.out.println(sum);
		}
	}
} public class Main {
 
	public static void main(String[] args) throws IOException {
		//File file = new File("input.txt");
		//Scanner in = new Scanner(file);
		
		Scanner in = new Scanner(System.in);
		
		int N = in.nextInt();
		int M = in.nextInt();
		int[][] edge = new int[N+1][N+1];
		for(int i = 0; i < M; i++){
			int a = in.nextInt();
			int b = in.nextInt();
			edge[a][b]++;
			edge[b][a]++;
		}
		
		for(int i = 1; i <= N; i++){
			int sum = 0;
			for(int j = 1; j <= N; j++) sum += edge[i][j];
			System.out.println(sum);
		}
	}
} Main
import java.io.File;
import java.io.IOException;
import java.util.ArrayDeque;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Comparator;
import java.util.Deque;
import java.util.List;
import java.util.Scanner;

public class Main {
 
	public static void main(String[] args) throws IOException {
		//File file = new File("input.txt");
		//Scanner in = new Scanner(file);
		
		Scanner in = new Scanner(System.in);
		
		int N = in.nextInt();
		int M = in.nextInt();
		int[][] edge = new int[N+1][N+1];
		for(int i = 0; i < M; i++){
			int a = in.nextInt();
			int b = in.nextInt();
			edge[a][b]++;
			edge[b][a]++;
		}
		
		for(int i = 1; i <= N; i++){
			int sum = 0;
			for(int j = 1; j <= N; j++) sum += edge[i][j];
			System.out.println(sum);
		}
	}
}
