import java.util.*;

public class Main{
  public static void main(String[]args){
    Scanner sc = new Scanner(System.in);
    int N = Integer.parseInt(sc.next());
    int M = Integer.parseInt(sc.next());
    int[] val = new int[N];
    for(int i = 0; i < M; i++){
      int a = Integer.parseInt(sc.next());
      int b = Integer.parseInt(sc.next());
      val[a-1]++;
      val[b-1]++;
    }
    for(int i = 0; i < N; i++){
      System.out.println(val[i]);
    }
  }
} import java.util.*; util.* java public class Main{
  public static void main(String[]args){
    Scanner sc = new Scanner(System.in);
    int N = Integer.parseInt(sc.next());
    int M = Integer.parseInt(sc.next());
    int[] val = new int[N];
    for(int i = 0; i < M; i++){
      int a = Integer.parseInt(sc.next());
      int b = Integer.parseInt(sc.next());
      val[a-1]++;
      val[b-1]++;
    }
    for(int i = 0; i < N; i++){
      System.out.println(val[i]);
    }
  }
} Main public static void main(String[]args){
    Scanner sc = new Scanner(System.in);
    int N = Integer.parseInt(sc.next());
    int M = Integer.parseInt(sc.next());
    int[] val = new int[N];
    for(int i = 0; i < M; i++){
      int a = Integer.parseInt(sc.next());
      int b = Integer.parseInt(sc.next());
      val[a-1]++;
      val[b-1]++;
    }
    for(int i = 0; i < N; i++){
      System.out.println(val[i]);
    }
  } main {
    Scanner sc = new Scanner(System.in);
    int N = Integer.parseInt(sc.next());
    int M = Integer.parseInt(sc.next());
    int[] val = new int[N];
    for(int i = 0; i < M; i++){
      int a = Integer.parseInt(sc.next());
      int b = Integer.parseInt(sc.next());
      val[a-1]++;
      val[b-1]++;
    }
    for(int i = 0; i < N; i++){
      System.out.println(val[i]);
    }
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int N = Integer.parseInt(sc.next()); N Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc int M = Integer.parseInt(sc.next()); M Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc int[] val = new int[N]; val new int[N] N for(int i = 0; i < M; i++){
      int a = Integer.parseInt(sc.next());
      int b = Integer.parseInt(sc.next());
      val[a-1]++;
      val[b-1]++;
    } int i = 0; int i = 0; i 0 i < M i M i++ i++ i {
      int a = Integer.parseInt(sc.next());
      int b = Integer.parseInt(sc.next());
      val[a-1]++;
      val[b-1]++;
    } {
      int a = Integer.parseInt(sc.next());
      int b = Integer.parseInt(sc.next());
      val[a-1]++;
      val[b-1]++;
    } int a = Integer.parseInt(sc.next()); a Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc int b = Integer.parseInt(sc.next()); b Integer.parseInt(sc.next()) Integer.parseInt Integer sc.next() sc.next sc val[a-1]++ val[a-1] val a-1 a 1 val[b-1]++ val[b-1] val b-1 b 1 for(int i = 0; i < N; i++){
      System.out.println(val[i]);
    } int i = 0; int i = 0; i 0 i < N i N i++ i++ i {
      System.out.println(val[i]);
    } {
      System.out.println(val[i]);
    } System.out.println(val[i]) System.out.println System.out System System.out val[i] val i String[]args args public class Main{
  public static void main(String[]args){
    Scanner sc = new Scanner(System.in);
    int N = Integer.parseInt(sc.next());
    int M = Integer.parseInt(sc.next());
    int[] val = new int[N];
    for(int i = 0; i < M; i++){
      int a = Integer.parseInt(sc.next());
      int b = Integer.parseInt(sc.next());
      val[a-1]++;
      val[b-1]++;
    }
    for(int i = 0; i < N; i++){
      System.out.println(val[i]);
    }
  }
} public class Main{
  public static void main(String[]args){
    Scanner sc = new Scanner(System.in);
    int N = Integer.parseInt(sc.next());
    int M = Integer.parseInt(sc.next());
    int[] val = new int[N];
    for(int i = 0; i < M; i++){
      int a = Integer.parseInt(sc.next());
      int b = Integer.parseInt(sc.next());
      val[a-1]++;
      val[b-1]++;
    }
    for(int i = 0; i < N; i++){
      System.out.println(val[i]);
    }
  }
} Main
import java.util.*;

public class Main{
  public static void main(String[]args){
    Scanner sc = new Scanner(System.in);
    int N = Integer.parseInt(sc.next());
    int M = Integer.parseInt(sc.next());
    int[] val = new int[N];
    for(int i = 0; i < M; i++){
      int a = Integer.parseInt(sc.next());
      int b = Integer.parseInt(sc.next());
      val[a-1]++;
      val[b-1]++;
    }
    for(int i = 0; i < N; i++){
      System.out.println(val[i]);
    }
  }
}