import java.util.Scanner;

public class Main{
  static int n, m;
  static int[] a, b;

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

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

    int[] d = new int[n];
    for(int i = 0; i < m; i++){
      d[a[i]]++;
      d[b[i]]++;
    }

    StringBuilder sb = new StringBuilder();
    for(int i = 0; i < n; i++){
      sb.append(d[i] + System.lineSeparator());
    }

    System.out.print(sb);
  }
} import java.util.Scanner; Scanner java.util public class Main{
  static int n, m;
  static int[] a, b;

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

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

    int[] d = new int[n];
    for(int i = 0; i < m; i++){
      d[a[i]]++;
      d[b[i]]++;
    }

    StringBuilder sb = new StringBuilder();
    for(int i = 0; i < n; i++){
      sb.append(d[i] + System.lineSeparator());
    }

    System.out.print(sb);
  }
} Main static int n n m; m static int[] a a b; b public static void main(String[] args){
    Scanner sc = new Scanner(System.in);

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

    int[] d = new int[n];
    for(int i = 0; i < m; i++){
      d[a[i]]++;
      d[b[i]]++;
    }

    StringBuilder sb = new StringBuilder();
    for(int i = 0; i < n; i++){
      sb.append(d[i] + System.lineSeparator());
    }

    System.out.print(sb);
  } main {
    Scanner sc = new Scanner(System.in);

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

    int[] d = new int[n];
    for(int i = 0; i < m; i++){
      d[a[i]]++;
      d[b[i]]++;
    }

    StringBuilder sb = new StringBuilder();
    for(int i = 0; i < n; i++){
      sb.append(d[i] + System.lineSeparator());
    }

    System.out.print(sb);
  } Scanner sc = new Scanner(System.in); sc new Scanner(System.in) n = sc.nextInt() n sc.nextInt() sc.nextInt sc m = sc.nextInt() m sc.nextInt() sc.nextInt sc a = new int[m] a new int[m] m b = new int[m] b new int[m] m for(int i = 0; i < m; i++){
      a[i] = sc.nextInt() - 1;
      b[i] = sc.nextInt() - 1;
    } int i = 0; int i = 0; i 0 i < m i m i++ i++ i {
      a[i] = sc.nextInt() - 1;
      b[i] = sc.nextInt() - 1;
    } {
      a[i] = sc.nextInt() - 1;
      b[i] = sc.nextInt() - 1;
    } a[i] = sc.nextInt() - 1 a[i] a i sc.nextInt() - 1 sc.nextInt() sc.nextInt sc 1 b[i] = sc.nextInt() - 1 b[i] b i sc.nextInt() - 1 sc.nextInt() sc.nextInt sc 1 int[] d = new int[n]; d new int[n] n for(int i = 0; i < m; i++){
      d[a[i]]++;
      d[b[i]]++;
    } int i = 0; int i = 0; i 0 i < m i m i++ i++ i {
      d[a[i]]++;
      d[b[i]]++;
    } {
      d[a[i]]++;
      d[b[i]]++;
    } d[a[i]]++ d[a[i]] d a[i] a i d[b[i]]++ d[b[i]] d b[i] b i StringBuilder sb = new StringBuilder(); sb new StringBuilder() for(int i = 0; i < n; i++){
      sb.append(d[i] + System.lineSeparator());
    } int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
      sb.append(d[i] + System.lineSeparator());
    } {
      sb.append(d[i] + System.lineSeparator());
    } sb.append(d[i] + System.lineSeparator()) sb.append sb d[i] + System.lineSeparator() d[i] d i System.lineSeparator() System.lineSeparator System System.out.print(sb) System.out.print System.out System System.out sb String[] args args public class Main{
  static int n, m;
  static int[] a, b;

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

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

    int[] d = new int[n];
    for(int i = 0; i < m; i++){
      d[a[i]]++;
      d[b[i]]++;
    }

    StringBuilder sb = new StringBuilder();
    for(int i = 0; i < n; i++){
      sb.append(d[i] + System.lineSeparator());
    }

    System.out.print(sb);
  }
} public class Main{
  static int n, m;
  static int[] a, b;

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

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

    int[] d = new int[n];
    for(int i = 0; i < m; i++){
      d[a[i]]++;
      d[b[i]]++;
    }

    StringBuilder sb = new StringBuilder();
    for(int i = 0; i < n; i++){
      sb.append(d[i] + System.lineSeparator());
    }

    System.out.print(sb);
  }
} Main
import java.util.Scanner;

public class Main{
  static int n, m;
  static int[] a, b;

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

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

    int[] d = new int[n];
    for(int i = 0; i < m; i++){
      d[a[i]]++;
      d[b[i]]++;
    }

    StringBuilder sb = new StringBuilder();
    for(int i = 0; i < n; i++){
      sb.append(d[i] + System.lineSeparator());
    }

    System.out.print(sb);
  }
}
