#include <iostream>
#include <algorithm>
#include <vector>

using namespace std;

vector < vector <int> > mv;
int c[100001];
int vi[100000];
int res[100000];

void vis(int ac, int cc){
	c[cc]++;
	vi[ac] = cc;
	for(int i=0;i<mv[ac].size();i++)if(vi[mv[ac][i]]==0)vis(mv[ac][i],cc);
}
int main(){
	
	cin.tie(0); ios_base::sync_with_stdio(0);
	int n,m,k;
	cin>>n>>m>>k;
	int u,v;
	mv.resize(n);
	while(m--){
		cin>>u>>v;
		u--;
		v--;
		mv[u].push_back(v);
		mv[v].push_back(u);
	}
	int cc=1;
	for(int i=0;i<n;i++)if(vi[i]==0){
		vis(i,cc);
		cc++;
	}
	while(k--){
		cin>>u>>v;
		u--;
		v--;
		if(vi[u]==vi[v]){
			res[u]++;
			res[v]++;
		}
	}
	for(int i=0;i<n;i++)cout<<c[vi[i]]-mv[i].size()-1-res[i]<<' ';
	cout<<endl;
	
	return 0;
}