// #define STOPIT
#include<bits/stdc++.h>
#define rep(i,n,m) for(int i = (n); i <(m); i++)
#define rrep(i,n,m) for(int i = (n) - 1; i >=(m); i--)
using namespace std;
using ll = long long;

void debug_impl() { cerr << endl; }
template <typename Head, typename... Tail>
void debug_impl(Head head, Tail... tail) { cerr << " " << head; debug_impl(tail...); }
#ifndef STOPIT
    #define debug(...)\
    do {\
        cerr << boolalpha << "[" << #__VA_ARGS__ << "]:";\
        debug_impl(__VA_ARGS__);\
        cerr << std::noboolalpha;\
    } while (false)
#else
    #define debug(...) {}
#endif

template < typename Container, typename Value = typename Container::value_type, enable_if_t<!is_same< Container, string >::value, nullptr_t> = nullptr>
istream& operator>> (istream& is, Container& v)
  { for (auto & x : v) { is >> x; } return is; }

template < typename Container, typename Value = typename Container::value_type, enable_if_t<!is_same< Container, string >::value, nullptr_t> = nullptr >
ostream& operator<< (ostream& os, Container const& v) {
  os << "{";
  for (auto it = v.begin(); it != v.end(); it++)
    {os << (it != v.begin() ? "," : "") << *it;}
  return os << "}";
}


struct UnionFind
{
    int n;
    vector<int> parent;
    vector<int> rank;
    UnionFind(int _n) :n(_n)
    {
        parent.assign(n, -1);
        rank.assign(n, 1);
    }

    int find(int i)
    {
        if (parent[i] == -1)
            return i;
        else
            return parent[i] = find(parent[i]);
    }

    void unite(int i, int j)
    {
        i = find(i);
        j = find(j);

        if (i == j) return;

        if (rank[i] == rank[j])
        {
            parent[j] = i;
            ++rank[i];
        }
        else
        {
            if (rank[i] < rank[j]) swap(i, j);
            parent[j] = i;
        }
    }

    bool is_same(int i, int j)
    {
        return find(i) == find(j);
    }
};

int main()
{
    // read input
    int N, M, K;
    cin >> N >> M >> K;
    vector<pair<int, int>> edge_ok;
    vector<pair<int, int>> edge_ng;
    
    rep(i, 0, M)
    {
        int A, B;
        cin >> A >> B;
        --A, --B;
        edge_ok.emplace_back(A, B);
    }
    rep(i, 0, K)
    {
        int C, D;
        cin >> C >> D;
        --C, --D;
        edge_ng.emplace_back(C, D);
    }

    // connect linking node with union find
    UnionFind uf(N);
    rep(i, 0, M)
        uf.unite(edge_ok[i].first, edge_ok[i].second);

    // count frined candidate
    vector<int> num_cand(N);
    rep(i, 0, N)
    {
        int par = uf.find(i);
        ++num_cand[par];
    }
    rep(i, 0, N)
        num_cand[i] = num_cand[uf.find(i)];

    // remove direct friend/block
    rep(i, 0, M)
    {
        int A, B;
        A = edge_ok[i].first;
        B = edge_ok[i].second;
        if (uf.is_same(A, B))
        {
            --num_cand[A];
            --num_cand[B];
        }
    }
    rep(i, 0, K)
    {
        int C, D;
        C = edge_ng[i].first;
        D = edge_ng[i].second;
        if (uf.is_same(D, C))
        {
            --num_cand[C];
            --num_cand[D];
        }
    }

    // print out result(remove count of itself)
    rep(i, 0, N)
        cout << num_cand[i]-1 << ' ';
    cout << endl;
    return 0;
}


Measured memory_bytes: 3572