#include <iostream>
#include <vector>
#include <cstdio>
using namespace std;

const int N = 1e5+9;
int n, m, k, a, b, p[N], ans[N], num[N];
//num：i里点数量
vector<int> vf[N], vb[N];

int fl(int x){
    return x == p[x] ? x : p[x] = fl(p[x]);
}

int main(){
    scanf("%d%d%d", &n, &m, &k);
    for(int i = 1; i <= n; i++) p[i] = i, num[i] = 1;
    for(int i = 1; i <= m; i++){
        scanf("%d%d", &a, &b);
        vf[a].push_back(b), vf[b].push_back(a);
        if(fl(a) != fl(b)){
            num[fl(b)] += num[fl(a)];
            p[fl(a)] = fl(b);
        }
    }
    for(int i = 1; i <= k; i++){
        scanf("%d%d", &a, &b);
        vb[a].push_back(b), vb[b].push_back(a);
    }
    for(int i = 1; i <= n; i++){
        ans[i] = num[fl(i)]-1;
        ans[i] -= vf[i].size();
        for(vector<int>::iterator it = vb[i].begin(); it != vb[i].end(); it++)
            ans[i] -= (fl(i) == fl(*it));
    }
    for(int i = 1; i <= n; i++) cout << ans[i] << " ";
    return 0;
}