import std.stdio, std.conv, std.string, std.algorithm,
       std.math, std.array, std.container, std.typecons;


int[] friend_group;

void main() {
  int n, m, k;
  readf("%d %d %d\n", &n, &m, &k);
  int[] friend_count = new int[n];
  int[] block_count = new int[n];
  friend_group = new int[](n);
  for(int i=0; i<m; i++) {
    int a, b;
    readf("%d %d\n", &a, &b);
    a--; b--;
    int ag = friend_group[a];
    int bg = friend_group[b];
    friend_count[a]++;
    friend_count[b]++;
    if(ag==0&&bg==0) {
      friend_group[a] = a+1;
      friend_group[b] = a+1;
      continue;
    }
    else if(ag>0&&bg==0) {
      friend_group[b] = friend_group[a];
      continue;
    }
    else if(ag==0&&bg>0) {
      friend_group[a] = friend_group[b];
      continue;
    }
    else {
      int fg = friend_group[b];
      for(int j=0; j<n; j++) if(friend_group[j]==fg) friend_group[j]=friend_group[a];
      continue;
    }
  }
  for(int i=0; i<k; i++) {
    int c, d;
    readf("%d %d\n", &c, &d);
    c--; d--;
    if(friend_group[c]==friend_group[d]&&friend_group[c]!=0&&friend_group[d]!=0) {
      block_count[c]++;
      block_count[d]++;
    }
  }
  int[] kouho_cuont = new int[n];
  for(int i=0; i<n; i++) if(friend_group[i]!=0) kouho_cuont[friend_group[i]-1]++;
  for(int i=0; i<n; i++) if(friend_group[i]!=0) kouho_cuont[i] = kouho_cuont[friend_group[i]-1];
  for(int i=0; i<n; i++) (kouho_cuont[i]-friend_count[i]-block_count[i]-1).writeln;
}

