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[] a_ = new int[M];
	int[] b_ = new int[M];

	for(int i = 0; i < M; i++){
	    a_[i] = scan.nextInt();
	    b_[i] = scan.nextInt();
	}

	int[] road_ = new int[N+1];
	for(int i = 0; i < M; i++){
	    road_[a_[i]]++;
	    road_[b_[i]]++;
	}

	for(int i = 1; i <= N; i++){
	    System.out.println(road_[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[] a_ = new int[M];
	int[] b_ = new int[M];

	for(int i = 0; i < M; i++){
	    a_[i] = scan.nextInt();
	    b_[i] = scan.nextInt();
	}

	int[] road_ = new int[N+1];
	for(int i = 0; i < M; i++){
	    road_[a_[i]]++;
	    road_[b_[i]]++;
	}

	for(int i = 1; i <= N; i++){
	    System.out.println(road_[i]);
	}
    }
} Main public static void main(String[] args){
	Scanner scan = new Scanner(System.in);

	int N = scan.nextInt();
	int M = scan.nextInt();
	
	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();
	}

	int[] road_ = new int[N+1];
	for(int i = 0; i < M; i++){
	    road_[a_[i]]++;
	    road_[b_[i]]++;
	}

	for(int i = 1; i <= N; i++){
	    System.out.println(road_[i]);
	}
    } main {
	Scanner scan = new Scanner(System.in);

	int N = scan.nextInt();
	int M = scan.nextInt();
	
	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();
	}

	int[] road_ = new int[N+1];
	for(int i = 0; i < M; i++){
	    road_[a_[i]]++;
	    road_[b_[i]]++;
	}

	for(int i = 1; i <= N; i++){
	    System.out.println(road_[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[] 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 int[] road_ = new int[N+1]; road_ new int[N+1] N+1 N 1 for(int i = 0; i < M; i++){
	    road_[a_[i]]++;
	    road_[b_[i]]++;
	} int i = 0; int i = 0; i 0 i < M i M i++ i++ i {
	    road_[a_[i]]++;
	    road_[b_[i]]++;
	} {
	    road_[a_[i]]++;
	    road_[b_[i]]++;
	} road_[a_[i]]++ road_[a_[i]] road_ a_[i] a_ i road_[b_[i]]++ road_[b_[i]] road_ b_[i] b_ i for(int i = 1; i <= N; i++){
	    System.out.println(road_[i]);
	} int i = 1; int i = 1; i 1 i <= N i N i++ i++ i {
	    System.out.println(road_[i]);
	} {
	    System.out.println(road_[i]);
	} System.out.println(road_[i]) System.out.println System.out System System.out road_[i] road_ 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[] a_ = new int[M];
	int[] b_ = new int[M];

	for(int i = 0; i < M; i++){
	    a_[i] = scan.nextInt();
	    b_[i] = scan.nextInt();
	}

	int[] road_ = new int[N+1];
	for(int i = 0; i < M; i++){
	    road_[a_[i]]++;
	    road_[b_[i]]++;
	}

	for(int i = 1; i <= N; i++){
	    System.out.println(road_[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[] a_ = new int[M];
	int[] b_ = new int[M];

	for(int i = 0; i < M; i++){
	    a_[i] = scan.nextInt();
	    b_[i] = scan.nextInt();
	}

	int[] road_ = new int[N+1];
	for(int i = 0; i < M; i++){
	    road_[a_[i]]++;
	    road_[b_[i]]++;
	}

	for(int i = 1; i <= N; i++){
	    System.out.println(road_[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[] a_ = new int[M];
	int[] b_ = new int[M];

	for(int i = 0; i < M; i++){
	    a_[i] = scan.nextInt();
	    b_[i] = scan.nextInt();
	}

	int[] road_ = new int[N+1];
	for(int i = 0; i < M; i++){
	    road_[a_[i]]++;
	    road_[b_[i]]++;
	}

	for(int i = 1; i <= N; i++){
	    System.out.println(road_[i]);
	}
    }
}
