import java.util.Scanner;

public class Main {
	public static void main(String[]args){
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();//年の数
		int M = scan.nextInt();
		
		int[] kazuN = new int[N];//都市ごとの本数
		
		
		int[] a = new int [M];
		int[] b = new int [M];
		
		for(int i = 0;i<M;i++){
			
			a[i] = scan.nextInt();
			b[i] = scan.nextInt();
			
		}
		
		
		for(int i = 0;i<M;i++){
			for(int j = 1;j<=N;j++){
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			}
			
		
		}
		
		
		
		
		
		
		
		
		
		
		
		for(int i = 0;i<N;i++){//入力したん個の都市ぶん出力
			System.out.println(kazuN[i]);	
		}
		
	}

} import java.util.Scanner; Scanner java.util public class Main {
	public static void main(String[]args){
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();//年の数
		int M = scan.nextInt();
		
		int[] kazuN = new int[N];//都市ごとの本数
		
		
		int[] a = new int [M];
		int[] b = new int [M];
		
		for(int i = 0;i<M;i++){
			
			a[i] = scan.nextInt();
			b[i] = scan.nextInt();
			
		}
		
		
		for(int i = 0;i<M;i++){
			for(int j = 1;j<=N;j++){
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			}
			
		
		}
		
		
		
		
		
		
		
		
		
		
		
		for(int i = 0;i<N;i++){//入力したん個の都市ぶん出力
			System.out.println(kazuN[i]);	
		}
		
	}

} Main public static void main(String[]args){
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();//年の数
		int M = scan.nextInt();
		
		int[] kazuN = new int[N];//都市ごとの本数
		
		
		int[] a = new int [M];
		int[] b = new int [M];
		
		for(int i = 0;i<M;i++){
			
			a[i] = scan.nextInt();
			b[i] = scan.nextInt();
			
		}
		
		
		for(int i = 0;i<M;i++){
			for(int j = 1;j<=N;j++){
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			}
			
		
		}
		
		
		
		
		
		
		
		
		
		
		
		for(int i = 0;i<N;i++){//入力したん個の都市ぶん出力
			System.out.println(kazuN[i]);	
		}
		
	} main {
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();//年の数
		int M = scan.nextInt();
		
		int[] kazuN = new int[N];//都市ごとの本数
		
		
		int[] a = new int [M];
		int[] b = new int [M];
		
		for(int i = 0;i<M;i++){
			
			a[i] = scan.nextInt();
			b[i] = scan.nextInt();
			
		}
		
		
		for(int i = 0;i<M;i++){
			for(int j = 1;j<=N;j++){
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			}
			
		
		}
		
		
		
		
		
		
		
		
		
		
		
		for(int i = 0;i<N;i++){//入力したん個の都市ぶん出力
			System.out.println(kazuN[i]);	
		}
		
	} Scanner scan = new Scanner(System.in); scan new Scanner(System.in) int N = scan.nextInt(); N scan.nextInt() scan.nextInt scan int M = scan.nextInt(); M scan.nextInt() scan.nextInt scan int[] kazuN = new int[N]; kazuN new int[N] N int[] a = new int [M]; a new int [M] M int[] b = new int [M]; b new int [M] M for(int i = 0;i<M;i++){
			
			a[i] = scan.nextInt();
			b[i] = scan.nextInt();
			
		} int i = 0; int i = 0; i 0 i<M i M i++ i++ i {
			
			a[i] = scan.nextInt();
			b[i] = scan.nextInt();
			
		} {
			
			a[i] = scan.nextInt();
			b[i] = scan.nextInt();
			
		} a[i] = scan.nextInt() a[i] a i scan.nextInt() scan.nextInt scan b[i] = scan.nextInt() b[i] b i scan.nextInt() scan.nextInt scan for(int i = 0;i<M;i++){
			for(int j = 1;j<=N;j++){
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			}
			
		
		} int i = 0; int i = 0; i 0 i<M i M i++ i++ i {
			for(int j = 1;j<=N;j++){
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			}
			
		
		} {
			for(int j = 1;j<=N;j++){
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			}
			
		
		} for(int j = 1;j<=N;j++){
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			} int j = 1; int j = 1; j 1 j<=N j N j++ j++ j {
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			} {
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			} if(j==a[i]){
					kazuN[j-1]+=1;
				} j==a[i] j a[i] a i {
					kazuN[j-1]+=1;
				} kazuN[j-1]+=1 kazuN[j-1] kazuN j-1 j 1 1 if(j==b[i]){
					kazuN[j-1]+=1;
				} j==b[i] j b[i] b i {
					kazuN[j-1]+=1;
				} kazuN[j-1]+=1 kazuN[j-1] kazuN j-1 j 1 1 for(int i = 0;i<N;i++){//入力したん個の都市ぶん出力
			System.out.println(kazuN[i]);	
		} int i = 0; int i = 0; i 0 i<N i N i++ i++ i {//入力したん個の都市ぶん出力
			System.out.println(kazuN[i]);	
		} {//入力したん個の都市ぶん出力
			System.out.println(kazuN[i]);	
		} System.out.println(kazuN[i]) System.out.println System.out System System.out kazuN[i] kazuN i String[]args args public class Main {
	public static void main(String[]args){
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();//年の数
		int M = scan.nextInt();
		
		int[] kazuN = new int[N];//都市ごとの本数
		
		
		int[] a = new int [M];
		int[] b = new int [M];
		
		for(int i = 0;i<M;i++){
			
			a[i] = scan.nextInt();
			b[i] = scan.nextInt();
			
		}
		
		
		for(int i = 0;i<M;i++){
			for(int j = 1;j<=N;j++){
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			}
			
		
		}
		
		
		
		
		
		
		
		
		
		
		
		for(int i = 0;i<N;i++){//入力したん個の都市ぶん出力
			System.out.println(kazuN[i]);	
		}
		
	}

} public class Main {
	public static void main(String[]args){
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();//年の数
		int M = scan.nextInt();
		
		int[] kazuN = new int[N];//都市ごとの本数
		
		
		int[] a = new int [M];
		int[] b = new int [M];
		
		for(int i = 0;i<M;i++){
			
			a[i] = scan.nextInt();
			b[i] = scan.nextInt();
			
		}
		
		
		for(int i = 0;i<M;i++){
			for(int j = 1;j<=N;j++){
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			}
			
		
		}
		
		
		
		
		
		
		
		
		
		
		
		for(int i = 0;i<N;i++){//入力したん個の都市ぶん出力
			System.out.println(kazuN[i]);	
		}
		
	}

} Main
import java.util.Scanner;

public class Main {
	public static void main(String[]args){
		Scanner scan = new Scanner(System.in);
		int N = scan.nextInt();//年の数
		int M = scan.nextInt();
		
		int[] kazuN = new int[N];//都市ごとの本数
		
		
		int[] a = new int [M];
		int[] b = new int [M];
		
		for(int i = 0;i<M;i++){
			
			a[i] = scan.nextInt();
			b[i] = scan.nextInt();
			
		}
		
		
		for(int i = 0;i<M;i++){
			for(int j = 1;j<=N;j++){
				
				if(j==a[i]){
					kazuN[j-1]+=1;
				}
				if(j==b[i]){
					kazuN[j-1]+=1;
				}
			
				
			}
			
		
		}
		
		
		
		
		
		
		
		
		
		
		
		for(int i = 0;i<N;i++){//入力したん個の都市ぶん出力
			System.out.println(kazuN[i]);	
		}
		
	}

}
