#include <bits/stdc++.h>
using namespace std;
typedef long long ll;

const int N = 100005;
int n, m, k;
vector<int> fr[N], bl[N];
int cc[N], sz[N];
bool vis[N];

void dfs(int u, int c) {
	vis[u] = 1;
	cc[u] = c;
	sz[c]++;
	for(auto& v : fr[u]) {
		if(!vis[v])
			dfs(v, c);
	}
}

int main() {
	ios::sync_with_stdio(false); cin.tie(NULL); cout.tie(NULL);
	cin >> n >> m >> k;
	for(int i = 0; i < m; i++) {
		int a, b; cin >> a >> b;
		fr[a].push_back(b);
		fr[b].push_back(a);
	}
	for(int i = 0; i < k; i++) {
		int a, b; cin >> a >> b;
		bl[a].push_back(b);
		bl[b].push_back(a);
	}

	int idx = 0;
	memset(vis, 0, sizeof vis);
	memset(sz, 0, sizeof sz);
	for(int i = 1; i <= n; i++) {
		if(!vis[i])
			dfs(i, ++idx);
	}

	for(int i = 1; i <= n; i++) {
		int ans = sz[cc[i]] - fr[i].size() - 1;
		for(auto& v : bl[i]) {
			if(cc[v] == cc[i]) ans--;
		}
		cout << ans << " ";
	}
	cout << '\n';

	return 0;
}