#include "bits/stdc++.h"
using namespace std;

const int N=1e5+20;

int n,m,k,u,v,color,col[N],dp[N];
vector <int> adj[N],blocked[N],nodes;
bool vis[N];

void dfs(int node)
{
	vis[node]=true;
	nodes.push_back(node);
	for(auto child:adj[node])
		if(not vis[child]) dfs(child);
}

int main()
{
	scanf("%d%d%d",&n,&m,&k);
	while(m--)
	{
		scanf("%d%d",&u,&v);
		adj[u].push_back(v);
		adj[v].push_back(u);
	}
	while(k--)
	{
		scanf("%d%d",&u,&v);
		blocked[u].push_back(v);
		blocked[v].push_back(u);
	}

	for(int i=1;i<=n;i++)
	{
		if(vis[i]) continue;
		color++;
		dfs(i);

		for(auto node:nodes)
			col[node]=color;

		int cc_size=nodes.size();
		while(not nodes.empty())
		{
			int node=nodes.back();
			nodes.pop_back();

			int blocked_in_cc=0;
			for(auto child:blocked[node])
				if(col[child]==color) blocked_in_cc++;
			dp[node]=cc_size-adj[node].size()-blocked_in_cc-1;
		}
	}

	for(int i=1;i<=n;i++)
		printf("%d ",dp[i]);
}