import java.util.*;

class Main {
  public static void main(String[] args) {

    Scanner scan = new Scanner(System.in);

    String elem[] = scan.nextLine().split(" ");

    int nbCity = Integer.parseInt(elem[0]);
    int nbRoad = Integer.parseInt(elem[1]);

    int[] connexion = new int[nbCity];

    for (int i = 0; i < nbRoad; i++){
        String[] connect = scan.nextLine().split(" ");
        if (Integer.parseInt(connect[0]) <= connexion.length){
          connexion[Integer.parseInt(connect[0]) - 1]++;
        }
        if (Integer.parseInt(connect[1]) <= connexion.length){
          connexion[Integer.parseInt(connect[1]) - 1]++;
        }
    }

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

  }
} import java.util.*; util.* java class Main {
  public static void main(String[] args) {

    Scanner scan = new Scanner(System.in);

    String elem[] = scan.nextLine().split(" ");

    int nbCity = Integer.parseInt(elem[0]);
    int nbRoad = Integer.parseInt(elem[1]);

    int[] connexion = new int[nbCity];

    for (int i = 0; i < nbRoad; i++){
        String[] connect = scan.nextLine().split(" ");
        if (Integer.parseInt(connect[0]) <= connexion.length){
          connexion[Integer.parseInt(connect[0]) - 1]++;
        }
        if (Integer.parseInt(connect[1]) <= connexion.length){
          connexion[Integer.parseInt(connect[1]) - 1]++;
        }
    }

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

  }
} Main public static void main(String[] args) {

    Scanner scan = new Scanner(System.in);

    String elem[] = scan.nextLine().split(" ");

    int nbCity = Integer.parseInt(elem[0]);
    int nbRoad = Integer.parseInt(elem[1]);

    int[] connexion = new int[nbCity];

    for (int i = 0; i < nbRoad; i++){
        String[] connect = scan.nextLine().split(" ");
        if (Integer.parseInt(connect[0]) <= connexion.length){
          connexion[Integer.parseInt(connect[0]) - 1]++;
        }
        if (Integer.parseInt(connect[1]) <= connexion.length){
          connexion[Integer.parseInt(connect[1]) - 1]++;
        }
    }

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

  } main {

    Scanner scan = new Scanner(System.in);

    String elem[] = scan.nextLine().split(" ");

    int nbCity = Integer.parseInt(elem[0]);
    int nbRoad = Integer.parseInt(elem[1]);

    int[] connexion = new int[nbCity];

    for (int i = 0; i < nbRoad; i++){
        String[] connect = scan.nextLine().split(" ");
        if (Integer.parseInt(connect[0]) <= connexion.length){
          connexion[Integer.parseInt(connect[0]) - 1]++;
        }
        if (Integer.parseInt(connect[1]) <= connexion.length){
          connexion[Integer.parseInt(connect[1]) - 1]++;
        }
    }

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

  } Scanner scan = new Scanner(System.in); scan new Scanner(System.in) String elem[] = scan.nextLine().split(" "); elem scan.nextLine().split(" ") scan.nextLine().split scan.nextLine() scan.nextLine scan " " int nbCity = Integer.parseInt(elem[0]); nbCity Integer.parseInt(elem[0]) Integer.parseInt Integer elem[0] elem 0 int nbRoad = Integer.parseInt(elem[1]); nbRoad Integer.parseInt(elem[1]) Integer.parseInt Integer elem[1] elem 1 int[] connexion = new int[nbCity]; connexion new int[nbCity] nbCity for (int i = 0; i < nbRoad; i++){
        String[] connect = scan.nextLine().split(" ");
        if (Integer.parseInt(connect[0]) <= connexion.length){
          connexion[Integer.parseInt(connect[0]) - 1]++;
        }
        if (Integer.parseInt(connect[1]) <= connexion.length){
          connexion[Integer.parseInt(connect[1]) - 1]++;
        }
    } int i = 0; int i = 0; i 0 i < nbRoad i nbRoad i++ i++ i {
        String[] connect = scan.nextLine().split(" ");
        if (Integer.parseInt(connect[0]) <= connexion.length){
          connexion[Integer.parseInt(connect[0]) - 1]++;
        }
        if (Integer.parseInt(connect[1]) <= connexion.length){
          connexion[Integer.parseInt(connect[1]) - 1]++;
        }
    } {
        String[] connect = scan.nextLine().split(" ");
        if (Integer.parseInt(connect[0]) <= connexion.length){
          connexion[Integer.parseInt(connect[0]) - 1]++;
        }
        if (Integer.parseInt(connect[1]) <= connexion.length){
          connexion[Integer.parseInt(connect[1]) - 1]++;
        }
    } String[] connect = scan.nextLine().split(" "); connect scan.nextLine().split(" ") scan.nextLine().split scan.nextLine() scan.nextLine scan " " if (Integer.parseInt(connect[0]) <= connexion.length){
          connexion[Integer.parseInt(connect[0]) - 1]++;
        } Integer.parseInt(connect[0]) <= connexion.length Integer.parseInt(connect[0]) Integer.parseInt Integer connect[0] connect 0 connexion.length connexion connexion.length {
          connexion[Integer.parseInt(connect[0]) - 1]++;
        } connexion[Integer.parseInt(connect[0]) - 1]++ connexion[Integer.parseInt(connect[0]) - 1] connexion Integer.parseInt(connect[0]) - 1 Integer.parseInt(connect[0]) Integer.parseInt Integer connect[0] connect 0 1 if (Integer.parseInt(connect[1]) <= connexion.length){
          connexion[Integer.parseInt(connect[1]) - 1]++;
        } Integer.parseInt(connect[1]) <= connexion.length Integer.parseInt(connect[1]) Integer.parseInt Integer connect[1] connect 1 connexion.length connexion connexion.length {
          connexion[Integer.parseInt(connect[1]) - 1]++;
        } connexion[Integer.parseInt(connect[1]) - 1]++ connexion[Integer.parseInt(connect[1]) - 1] connexion Integer.parseInt(connect[1]) - 1 Integer.parseInt(connect[1]) Integer.parseInt Integer connect[1] connect 1 1 for (int i = 0; i < nbCity; i++){
      System.out.println(connexion[i]);
    } int i = 0; int i = 0; i 0 i < nbCity i nbCity i++ i++ i {
      System.out.println(connexion[i]);
    } {
      System.out.println(connexion[i]);
    } System.out.println(connexion[i]) System.out.println System.out System System.out connexion[i] connexion i String[] args args
import java.util.*;

class Main {
  public static void main(String[] args) {

    Scanner scan = new Scanner(System.in);

    String elem[] = scan.nextLine().split(" ");

    int nbCity = Integer.parseInt(elem[0]);
    int nbRoad = Integer.parseInt(elem[1]);

    int[] connexion = new int[nbCity];

    for (int i = 0; i < nbRoad; i++){
        String[] connect = scan.nextLine().split(" ");
        if (Integer.parseInt(connect[0]) <= connexion.length){
          connexion[Integer.parseInt(connect[0]) - 1]++;
        }
        if (Integer.parseInt(connect[1]) <= connexion.length){
          connexion[Integer.parseInt(connect[1]) - 1]++;
        }
    }

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

  }
}
