import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author mikit
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BCountingRoads solver = new BCountingRoads();
        solver.solve(1, in, out);
        out.close();
    }

    static class BCountingRoads {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int n = in.nextInt(), m = in.nextInt();
            int[] ans = new int[n];
            for (int i = 0; i < 2 * m; i++) {
                ans[in.nextInt() - 1]++;
            }
            for (int a : ans) {
                out.println(a);
            }
        }

    }
}
 import java.io.OutputStream; OutputStream java.io import java.io.IOException; IOException java.io import java.io.InputStream; InputStream java.io import java.io.PrintWriter; PrintWriter java.io import java.util.Scanner; Scanner java.util public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BCountingRoads solver = new BCountingRoads();
        solver.solve(1, in, out);
        out.close();
    }

    static class BCountingRoads {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int n = in.nextInt(), m = in.nextInt();
            int[] ans = new int[n];
            for (int i = 0; i < 2 * m; i++) {
                ans[in.nextInt() - 1]++;
            }
            for (int a : ans) {
                out.println(a);
            }
        }

    }
} Main public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BCountingRoads solver = new BCountingRoads();
        solver.solve(1, in, out);
        out.close();
    } main {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BCountingRoads solver = new BCountingRoads();
        solver.solve(1, in, out);
        out.close();
    } InputStream inputStream = System.in; inputStream System.in System System.in OutputStream outputStream = System.out; outputStream System.out System System.out Scanner in = new Scanner(inputStream); in new Scanner(inputStream) PrintWriter out = new PrintWriter(outputStream); out new PrintWriter(outputStream) BCountingRoads solver = new BCountingRoads(); solver new BCountingRoads() solver.solve(1, in, out) solver.solve solver 1 in out out.close() out.close out String[] args args static class BCountingRoads {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int n = in.nextInt(), m = in.nextInt();
            int[] ans = new int[n];
            for (int i = 0; i < 2 * m; i++) {
                ans[in.nextInt() - 1]++;
            }
            for (int a : ans) {
                out.println(a);
            }
        }

    } BCountingRoads public void solve(int testNumber, Scanner in, PrintWriter out) {
            int n = in.nextInt(), m = in.nextInt();
            int[] ans = new int[n];
            for (int i = 0; i < 2 * m; i++) {
                ans[in.nextInt() - 1]++;
            }
            for (int a : ans) {
                out.println(a);
            }
        } solve {
            int n = in.nextInt(), m = in.nextInt();
            int[] ans = new int[n];
            for (int i = 0; i < 2 * m; i++) {
                ans[in.nextInt() - 1]++;
            }
            for (int a : ans) {
                out.println(a);
            }
        } int n = in.nextInt() n in.nextInt() in.nextInt in m = in.nextInt(); m in.nextInt() in.nextInt in int[] ans = new int[n]; ans new int[n] n for (int i = 0; i < 2 * m; i++) {
                ans[in.nextInt() - 1]++;
            } int i = 0; int i = 0; i 0 i < 2 * m i 2 * m 2 m i++ i++ i {
                ans[in.nextInt() - 1]++;
            } {
                ans[in.nextInt() - 1]++;
            } ans[in.nextInt() - 1]++ ans[in.nextInt() - 1] ans in.nextInt() - 1 in.nextInt() in.nextInt in 1 for (int a : ans) {
                out.println(a);
            } int a ans {
                out.println(a);
            } {
                out.println(a);
            } out.println(a) out.println out a int testNumber testNumber Scanner in in PrintWriter out out public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BCountingRoads solver = new BCountingRoads();
        solver.solve(1, in, out);
        out.close();
    }

    static class BCountingRoads {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int n = in.nextInt(), m = in.nextInt();
            int[] ans = new int[n];
            for (int i = 0; i < 2 * m; i++) {
                ans[in.nextInt() - 1]++;
            }
            for (int a : ans) {
                out.println(a);
            }
        }

    }
} public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BCountingRoads solver = new BCountingRoads();
        solver.solve(1, in, out);
        out.close();
    }

    static class BCountingRoads {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int n = in.nextInt(), m = in.nextInt();
            int[] ans = new int[n];
            for (int i = 0; i < 2 * m; i++) {
                ans[in.nextInt() - 1]++;
            }
            for (int a : ans) {
                out.println(a);
            }
        }

    }
} Main
import java.io.OutputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.PrintWriter;
import java.util.Scanner;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 *
 * @author mikit
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        Scanner in = new Scanner(inputStream);
        PrintWriter out = new PrintWriter(outputStream);
        BCountingRoads solver = new BCountingRoads();
        solver.solve(1, in, out);
        out.close();
    }

    static class BCountingRoads {
        public void solve(int testNumber, Scanner in, PrintWriter out) {
            int n = in.nextInt(), m = in.nextInt();
            int[] ans = new int[n];
            for (int i = 0; i < 2 * m; i++) {
                ans[in.nextInt() - 1]++;
            }
            for (int a : ans) {
                out.println(a);
            }
        }

    }
}

