#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, m, k;
  cin >> n >> m >> k;
  set<long long> arr[n];
  for (long long i = 0; i <= m - 1; i++) {
    long long a, b;
    cin >> a >> b;
    a--;
    b--;
    if (a != b) {
      arr[a].insert(b);
      arr[b].insert(a);
    }
  }
  set<set<long long>> line;
  long long visited[n];
  long long visited_count = 0;
  for (long long i = 0; i <= n - 1; i++) {
    visited[i] = 0;
  }
  while (visited_count <= n - 1) {
    long long base_ = -1;
    for (long long i = 0; i <= n - 1; i++) {
      if (visited[i] == 0) {
        base_ = i;
        break;
      }
    }
    set<long long> temp;
    stack<long long> calc;
    calc.push(base_);
    while (calc.size() != 0) {
      long long q = calc.top();
      calc.pop();
      temp.insert(q);
      visited[q] = 1;
      visited_count++;
      for (auto it = arr[q].begin(); it != arr[q].end(); it++) {
        if (visited[*it] == 0) {
          calc.push(*it);
        }
      }
    }
    line.insert(temp);
  }
  pair<long long, long long> ans[n];
  for (long long i = 0; i <= n - 1; i++) {
    ans[i].first = 0;
    ans[i].second = -1;
  }
  long long count = 0;
  for (auto it = line.begin(); it != line.end(); it++) {
    set<long long> temp = *it;
    for (auto it2 = temp.begin(); it2 != temp.end(); it2++) {
      ans[*it2].first = temp.size() - arr[*it2].size();
      ans[*it2].second = count;
    }
    count++;
  }
  for (long long i = 0; i <= k - 1; i++) {
    long long a, b;
    cin >> a >> b;
    a--;
    b--;
    if ((ans[a].second == ans[b].second) && (a != b)) {
      ans[a].first--;
      ans[b].first--;
    }
  }
  for (long long i = 0; i <= n - 1; i++) {
    cout << ans[i].first - 1 << " ";
  }
  cout << "\n";
  return 0;
}
