#include<bits/stdc++.h>
#define M 100008
using namespace std;
int f[M],sum[M],st[M],ne[M];
int zm(int x)
{
	return f[x]==x?x:f[x]=zm(f[x]);
}
void jiebai (int x,int y)
{
	int f1=zm(f[x]),f2=zm(f[y]);
	if(f1!=f2)f[f1]=f2;
	return;
}
int main()
{
	int n,m,k;
	cin>>n>>m>>k;
	for(int i=1;i<=n;++i)f[i]=i;
	for(int i=1;i<=m;++i)
	{
		int a,b;
		cin>>a>>b;
		st[a]++;
		st[b]++;
		jiebai(a,b);
	}
	for(int i=1;i<=n;++i)
	{
		f[i]=zm(i);
	}
	for(int i=1;i<=n;++i)
	{
		sum[f[i]]++;
	}
	for(int i=1;i<=k;++i)
	{
		int a,b;
		cin>>a>>b;
		if(f[a]==f[b])
		{
			ne[a]++;
			ne[b]++;
		}
	}
	for(int i=1;i<=n;++i)
	{
		int ans=sum[f[i]]-st[i]-ne[i]-1;
		cout<<ans<<" ";
	}
}