#include <iostream>
#include <vector>
#include <array>
#include <set>
#include <cmath>
#include <string>
#include <sstream>
#include <queue> 
#include <list>
#include <stack>
#include <unordered_map>
#include <algorithm> 
#include <numeric>  
#include <functional>
#include <cassert>
#include <bitset>
#include <cctype>  
#include <iomanip> 
#include <limits>  
#include <regex>
// std::numeric_limits<int>::max(), min()
// std::setprecision(X)
// std::islower(), std::isupper(), std::tolower, std::toupper
// std::accumulate(m.begin(), m.end(), 0LL);
// std::sort(begin(),end()) // 0, 1, 2, 3 ,4 (default, less);
// std::priority_queue<int, vector<int>, less<int>> que; // 4, 3, 2, 1 (defualt, less) : 
// if ( std::regex_match(S, std::regex("(dream|dreamer|erase|eraser)*")) ) std::cout << "YES" << std::endl;
 
#define rep(i, n) for(int i = 0; i < (int)(n);    i++)
#define sz(x) ((int)(x).size())
#define all(x) (x).begin(),(x).end()

template<class T>bool chmax(T &a, const T &b) { if (a<b) { a=b; return 1; } return 0; }
template<class T>bool chmin(T &a, const T &b) { if (b<a) { a=b; return 1; } return 0; }
typedef long long ll;
typedef std::vector<int> vi;
typedef std::vector<std::vector<int>> vvi;

ll gcd ( ll a, ll b ) { if ( b == 0 ) return a; else return gcd ( b, a%b ); }
ll lcm ( ll a, ll b ) { return a * b / gcd(a, b); }

using namespace std;

/*
template <class T> class UnionFind {
  private:
    struct subset  { 
      int parent; 
      int rank;
      T diff_weight;
      int sizes;
    }; 
    std::vector<subset> subsets;

  public:
    UnionFind (int N) {
      subsets.resize(N);
      for(int i=0; i<N; i++) subsets[i] = subset( { i, 0, T(0), 1 } );
    }

    int Find (int x) { 
      if (subsets[x].parent == x) return x;
      int r = Find(subsets[x].parent); 
      subsets[x].diff_weight += subsets[subsets[x].parent].diff_weight;
      return subsets[x].parent = r; 
    } 

    T weight(int x) {
      Find(x);
      return subsets[x].diff_weight;
    }

    bool Same (int x, int y) {
        return Find(x) == Find(y);
    }

    bool Union (int x, int y, T w) {
      w += weight(x); w -= weight(y);
      x = Find(x);  y = Find(y); 
      if ( x == y ) return false;

      if (subsets[x].rank < subsets[y].rank) {
        std::swap(x, y);
        w = -w;
      }
      if (subsets[x].rank == subsets[y].rank) {
        subsets[x].rank++; 
        subsets[x].sizes += subsets[y].sizes;
      }
      subsets[y].parent = x;
      subsets[y].diff_weight = w;
      return true;
    }

    T diff(int x, int y) {
      assert( Same(x,y) );
      return weight(y) - weight(x);
    }

    int size (int x) {
      return subsets[Find(x)].sizes;
    }
};

*/

// union by size + path having
class UnionFind {
public:
    vector <ll> par; // 各元の親を表す配列
    vector <ll> siz; // 素集合のサイズを表す配列(1 で初期化)

    // Constructor
    UnionFind(ll sz_): par(sz_), siz(sz_, 1LL) {
        for (ll i = 0; i < sz_; ++i) par[i] = i; // 初期では親は自分自身
    }
    void init(ll sz_) {
        par.resize(sz_);
        siz.assign(sz_, 1LL);  // resize だとなぜか初期化されなかった
        for (ll i = 0; i < sz_; ++i) par[i] = i; // 初期では親は自分自身
    }

    // Member Function
    // Find
    ll root(ll x) { // 根の検索
        while (par[x] != x) {
            x = par[x] = par[par[x]]; // x の親の親を x の親とする
        }
        return x;
    }

    // Union(Unite, Merge)
    bool merge(ll x, ll y) {
        x = root(x);
        y = root(y);
        if (x == y) return false;
        // merge technique（データ構造をマージするテク．小を大にくっつける）
        if (siz[x] < siz[y]) swap(x, y);
        siz[x] += siz[y];
        par[y] = x;
        return true;
    }

    bool issame(ll x, ll y) { // 連結判定
        return root(x) == root(y);
    }

    ll size(ll x) { // 素集合のサイズ
        return siz[root(x)];
    }
};

int main (void) {
  std::cin.tie(0);  std::ios::sync_with_stdio(false);
  int N, M, K; std::cin >> N >> M >> K;
  std::vector<std::vector<int>> G(N);
  UnionFind uf(N);
  rep(i,M) {
    int A, B; std::cin >> A >> B;
    A--, B--;
    G[A].push_back(B);
    G[B].push_back(A);
    uf.merge(A, B);
  }
  rep(i,K) {
    int C, D; std::cin >> C >> D;
    C--, D--;
    G[C].push_back(D);
    G[D].push_back(C);
  }

  rep(i,N) {
    int cnt = 0;
    rep(j, sz(G[i])) if ( uf.issame(i, G[i][j]) ) cnt++;
    std::cout << uf.size(i) - cnt - 1 << " ";
  }
  std::cout << std::endl;

  return 0;
}


Measured memory_bytes: 9088