
import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int m = sc.nextInt();
        int[][] es = new int[n][n];
        for (int i = 0; i < m; i++) {
            int a = sc.nextInt() - 1;
            int b = sc.nextInt() - 1;
            es[a][b]++;es[b][a]++;
        }
        for (int i = 0; i < n; i++) {
            int each = 0;
            for (int j =0; j < n; j++) {
                if (es[i][j] != 0) each += es[i][j];
            }
            System.out.println(each);
        }
    }
} import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int m = sc.nextInt();
        int[][] es = new int[n][n];
        for (int i = 0; i < m; i++) {
            int a = sc.nextInt() - 1;
            int b = sc.nextInt() - 1;
            es[a][b]++;es[b][a]++;
        }
        for (int i = 0; i < n; i++) {
            int each = 0;
            for (int j =0; j < n; j++) {
                if (es[i][j] != 0) each += es[i][j];
            }
            System.out.println(each);
        }
    }
} Main public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int m = sc.nextInt();
        int[][] es = new int[n][n];
        for (int i = 0; i < m; i++) {
            int a = sc.nextInt() - 1;
            int b = sc.nextInt() - 1;
            es[a][b]++;es[b][a]++;
        }
        for (int i = 0; i < n; i++) {
            int each = 0;
            for (int j =0; j < n; j++) {
                if (es[i][j] != 0) each += es[i][j];
            }
            System.out.println(each);
        }
    } main {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int m = sc.nextInt();
        int[][] es = new int[n][n];
        for (int i = 0; i < m; i++) {
            int a = sc.nextInt() - 1;
            int b = sc.nextInt() - 1;
            es[a][b]++;es[b][a]++;
        }
        for (int i = 0; i < n; i++) {
            int each = 0;
            for (int j =0; j < n; j++) {
                if (es[i][j] != 0) each += es[i][j];
            }
            System.out.println(each);
        }
    } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int m = sc.nextInt(); m sc.nextInt() sc.nextInt sc int[][] es = new int[n][n]; es new int[n][n] n n for (int i = 0; i < m; i++) {
            int a = sc.nextInt() - 1;
            int b = sc.nextInt() - 1;
            es[a][b]++;es[b][a]++;
        } int i = 0; int i = 0; i 0 i < m i m i++ i++ i {
            int a = sc.nextInt() - 1;
            int b = sc.nextInt() - 1;
            es[a][b]++;es[b][a]++;
        } {
            int a = sc.nextInt() - 1;
            int b = sc.nextInt() - 1;
            es[a][b]++;es[b][a]++;
        } int a = sc.nextInt() - 1; a sc.nextInt() - 1 sc.nextInt() sc.nextInt sc 1 int b = sc.nextInt() - 1; b sc.nextInt() - 1 sc.nextInt() sc.nextInt sc 1 es[a][b]++ es[a][b] es[a] es a b es[b][a]++ es[b][a] es[b] es b a for (int i = 0; i < n; i++) {
            int each = 0;
            for (int j =0; j < n; j++) {
                if (es[i][j] != 0) each += es[i][j];
            }
            System.out.println(each);
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
            int each = 0;
            for (int j =0; j < n; j++) {
                if (es[i][j] != 0) each += es[i][j];
            }
            System.out.println(each);
        } {
            int each = 0;
            for (int j =0; j < n; j++) {
                if (es[i][j] != 0) each += es[i][j];
            }
            System.out.println(each);
        } int each = 0; each 0 for (int j =0; j < n; j++) {
                if (es[i][j] != 0) each += es[i][j];
            } int j =0; int j =0; j 0 j < n j n j++ j++ j {
                if (es[i][j] != 0) each += es[i][j];
            } {
                if (es[i][j] != 0) each += es[i][j];
            } if (es[i][j] != 0) each += es[i][j]; es[i][j] != 0 es[i][j] es[i] es i j 0 each += es[i][j] each es[i][j] es[i] es i j System.out.println(each) System.out.println System.out System System.out each String[] args args public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int m = sc.nextInt();
        int[][] es = new int[n][n];
        for (int i = 0; i < m; i++) {
            int a = sc.nextInt() - 1;
            int b = sc.nextInt() - 1;
            es[a][b]++;es[b][a]++;
        }
        for (int i = 0; i < n; i++) {
            int each = 0;
            for (int j =0; j < n; j++) {
                if (es[i][j] != 0) each += es[i][j];
            }
            System.out.println(each);
        }
    }
} public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int m = sc.nextInt();
        int[][] es = new int[n][n];
        for (int i = 0; i < m; i++) {
            int a = sc.nextInt() - 1;
            int b = sc.nextInt() - 1;
            es[a][b]++;es[b][a]++;
        }
        for (int i = 0; i < n; i++) {
            int each = 0;
            for (int j =0; j < n; j++) {
                if (es[i][j] != 0) each += es[i][j];
            }
            System.out.println(each);
        }
    }
} Main

import java.util.Scanner;

public class Main {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        int n = sc.nextInt();
        int m = sc.nextInt();
        int[][] es = new int[n][n];
        for (int i = 0; i < m; i++) {
            int a = sc.nextInt() - 1;
            int b = sc.nextInt() - 1;
            es[a][b]++;es[b][a]++;
        }
        for (int i = 0; i < n; i++) {
            int each = 0;
            for (int j =0; j < n; j++) {
                if (es[i][j] != 0) each += es[i][j];
            }
            System.out.println(each);
        }
    }
}
