import java.util.*;

public class Main {
    public static int solve() {
        return 0;
    }

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int m = sc.nextInt();
        int[] roads = new int[n];

        for (int i = 0; i < m; i++) {
            roads[sc.nextInt()-1]++;
            roads[sc.nextInt()-1]++;
        }

        for (int i = 0; i < n; i++) {
            System.out.println(roads[i]);
        }
    }
} import java.util.*; util.* java public class Main {
    public static int solve() {
        return 0;
    }

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int m = sc.nextInt();
        int[] roads = new int[n];

        for (int i = 0; i < m; i++) {
            roads[sc.nextInt()-1]++;
            roads[sc.nextInt()-1]++;
        }

        for (int i = 0; i < n; i++) {
            System.out.println(roads[i]);
        }
    }
} Main public static int solve() {
        return 0;
    } solve {
        return 0;
    } return 0; 0 public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int m = sc.nextInt();
        int[] roads = new int[n];

        for (int i = 0; i < m; i++) {
            roads[sc.nextInt()-1]++;
            roads[sc.nextInt()-1]++;
        }

        for (int i = 0; i < n; i++) {
            System.out.println(roads[i]);
        }
    } main {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int m = sc.nextInt();
        int[] roads = new int[n];

        for (int i = 0; i < m; i++) {
            roads[sc.nextInt()-1]++;
            roads[sc.nextInt()-1]++;
        }

        for (int i = 0; i < n; i++) {
            System.out.println(roads[i]);
        }
    } 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[] roads = new int[n]; roads new int[n] n for (int i = 0; i < m; i++) {
            roads[sc.nextInt()-1]++;
            roads[sc.nextInt()-1]++;
        } int i = 0; int i = 0; i 0 i < m i m i++ i++ i {
            roads[sc.nextInt()-1]++;
            roads[sc.nextInt()-1]++;
        } {
            roads[sc.nextInt()-1]++;
            roads[sc.nextInt()-1]++;
        } roads[sc.nextInt()-1]++ roads[sc.nextInt()-1] roads sc.nextInt()-1 sc.nextInt() sc.nextInt sc 1 roads[sc.nextInt()-1]++ roads[sc.nextInt()-1] roads sc.nextInt()-1 sc.nextInt() sc.nextInt sc 1 for (int i = 0; i < n; i++) {
            System.out.println(roads[i]);
        } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
            System.out.println(roads[i]);
        } {
            System.out.println(roads[i]);
        } System.out.println(roads[i]) System.out.println System.out System System.out roads[i] roads i String[] args args public class Main {
    public static int solve() {
        return 0;
    }

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int m = sc.nextInt();
        int[] roads = new int[n];

        for (int i = 0; i < m; i++) {
            roads[sc.nextInt()-1]++;
            roads[sc.nextInt()-1]++;
        }

        for (int i = 0; i < n; i++) {
            System.out.println(roads[i]);
        }
    }
} public class Main {
    public static int solve() {
        return 0;
    }

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int m = sc.nextInt();
        int[] roads = new int[n];

        for (int i = 0; i < m; i++) {
            roads[sc.nextInt()-1]++;
            roads[sc.nextInt()-1]++;
        }

        for (int i = 0; i < n; i++) {
            System.out.println(roads[i]);
        }
    }
} Main
import java.util.*;

public class Main {
    public static int solve() {
        return 0;
    }

    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);

        int n = sc.nextInt();
        int m = sc.nextInt();
        int[] roads = new int[n];

        for (int i = 0; i < m; i++) {
            roads[sc.nextInt()-1]++;
            roads[sc.nextInt()-1]++;
        }

        for (int i = 0; i < n; i++) {
            System.out.println(roads[i]);
        }
    }
}
