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[] num_road=new int[N];
        int[] a=new int[M];
        int[] b=new int[M];
        int i;
        for(i=0;i<N;i++){
            num_road[i]=0;
        }
        for(i=0;i<M;i++){
            a[i]=scan.nextInt();
            b[i]=scan.nextInt();
            num_road[a[i]-1]++;
            num_road[b[i]-1]++;
        }
        for(i=0;i<N;i++){
            System.out.println(num_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[] num_road=new int[N];
        int[] a=new int[M];
        int[] b=new int[M];
        int i;
        for(i=0;i<N;i++){
            num_road[i]=0;
        }
        for(i=0;i<M;i++){
            a[i]=scan.nextInt();
            b[i]=scan.nextInt();
            num_road[a[i]-1]++;
            num_road[b[i]-1]++;
        }
        for(i=0;i<N;i++){
            System.out.println(num_road[i]);
        }
    }
} Main public static void main(String args[]){
        Scanner scan=new Scanner(System.in);
        int N=scan.nextInt();
        int M=scan.nextInt();
        int[] num_road=new int[N];
        int[] a=new int[M];
        int[] b=new int[M];
        int i;
        for(i=0;i<N;i++){
            num_road[i]=0;
        }
        for(i=0;i<M;i++){
            a[i]=scan.nextInt();
            b[i]=scan.nextInt();
            num_road[a[i]-1]++;
            num_road[b[i]-1]++;
        }
        for(i=0;i<N;i++){
            System.out.println(num_road[i]);
        }
    } main {
        Scanner scan=new Scanner(System.in);
        int N=scan.nextInt();
        int M=scan.nextInt();
        int[] num_road=new int[N];
        int[] a=new int[M];
        int[] b=new int[M];
        int i;
        for(i=0;i<N;i++){
            num_road[i]=0;
        }
        for(i=0;i<M;i++){
            a[i]=scan.nextInt();
            b[i]=scan.nextInt();
            num_road[a[i]-1]++;
            num_road[b[i]-1]++;
        }
        for(i=0;i<N;i++){
            System.out.println(num_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[] num_road=new int[N]; num_road new int[N] N int[] a=new int[M]; a new int[M] M int[] b=new int[M]; b new int[M] M int i; i for(i=0;i<N;i++){
            num_road[i]=0;
        } i=0; i=0 i 0 i<N i N i++ i++ i {
            num_road[i]=0;
        } {
            num_road[i]=0;
        } num_road[i]=0 num_road[i] num_road i 0 for(i=0;i<M;i++){
            a[i]=scan.nextInt();
            b[i]=scan.nextInt();
            num_road[a[i]-1]++;
            num_road[b[i]-1]++;
        } i=0; i=0 i 0 i<M i M i++ i++ i {
            a[i]=scan.nextInt();
            b[i]=scan.nextInt();
            num_road[a[i]-1]++;
            num_road[b[i]-1]++;
        } {
            a[i]=scan.nextInt();
            b[i]=scan.nextInt();
            num_road[a[i]-1]++;
            num_road[b[i]-1]++;
        } 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 num_road[a[i]-1]++ num_road[a[i]-1] num_road a[i]-1 a[i] a i 1 num_road[b[i]-1]++ num_road[b[i]-1] num_road b[i]-1 b[i] b i 1 for(i=0;i<N;i++){
            System.out.println(num_road[i]);
        } i=0; i=0 i 0 i<N i N i++ i++ i {
            System.out.println(num_road[i]);
        } {
            System.out.println(num_road[i]);
        } System.out.println(num_road[i]) System.out.println System.out System System.out num_road[i] num_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[] num_road=new int[N];
        int[] a=new int[M];
        int[] b=new int[M];
        int i;
        for(i=0;i<N;i++){
            num_road[i]=0;
        }
        for(i=0;i<M;i++){
            a[i]=scan.nextInt();
            b[i]=scan.nextInt();
            num_road[a[i]-1]++;
            num_road[b[i]-1]++;
        }
        for(i=0;i<N;i++){
            System.out.println(num_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[] num_road=new int[N];
        int[] a=new int[M];
        int[] b=new int[M];
        int i;
        for(i=0;i<N;i++){
            num_road[i]=0;
        }
        for(i=0;i<M;i++){
            a[i]=scan.nextInt();
            b[i]=scan.nextInt();
            num_road[a[i]-1]++;
            num_road[b[i]-1]++;
        }
        for(i=0;i<N;i++){
            System.out.println(num_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[] num_road=new int[N];
        int[] a=new int[M];
        int[] b=new int[M];
        int i;
        for(i=0;i<N;i++){
            num_road[i]=0;
        }
        for(i=0;i<M;i++){
            a[i]=scan.nextInt();
            b[i]=scan.nextInt();
            num_road[a[i]-1]++;
            num_road[b[i]-1]++;
        }
        for(i=0;i<N;i++){
            System.out.println(num_road[i]);
        }
    }
}