# Original solution
class UnionFind():
    def __init__(self, n):
        self.n = n
        self.parents = [-1] * n

    def find(self, x):
        if self.parents[x] < 0:
            return x
        else:
            self.parents[x] = self.find(self.parents[x])
            return self.parents[x]

    def union(self, x, y):
        x = self.find(x)
        y = self.find(y)

        if x == y:
            return

        if self.parents[x] > self.parents[y]:
            x, y = y, x

        self.parents[x] += self.parents[y]
        self.parents[y] = x

    def size(self, x):
        return -self.parents[self.find(x)]

    def same(self, x, y):
        return self.find(x) == self.find(y)

    def members(self, x):
        root = self.find(x)
        return [i for i in range(self.n) if self.find(i) == root]

    def roots(self):
        return [i for i, x in enumerate(self.parents) if x < 0]

    def group_count(self):
        return len(self.roots())

    def all_group_members(self):
        return {r: self.members(r) for r in self.roots()}

    def __str__(self):
        return '\n'.join('{}: {}'.format(r, self.members(r)) for r in self.roots())


n, m, k = list(map(int, input().split()))
from collections import defaultdict

fr = defaultdict(set)
bl = defaultdict(set)
kouho = defaultdict(set)
al = set(range(1, n+1))
ans = [0] * n
uf = UnionFind(n+1)


for _ in range(1, m+1):
    a, b = list(map(int, input().split()))
    fr[a].add(b)
    fr[b].add(a)
    uf.union(a, b)
for _ in range(1, k+1):
    c, d = list(map(int, input().split()))
    bl[c].add(d)
    bl[d].add(c)

for i in range(1, n+1):
    kouho[i] = al - (fr[i] | bl[i]) - {i}

# print(kouho)
# print(uf)

for k, v in list(kouho.items()):

    if len(v) == 0:
        # print(f"{k}は友達候補なし")
        continue
    # print(f"{k}は　候補が{v}")
    rel = set()
    while(len(v) > 0):
        kk = v.pop()
        if uf.same(k, kk):
            ans[k-1] += 1
            # print(f"{k}の友達候補確定：{kk}")





print((" ".join([str(i) for i in ans])))

# Optimized solution
class UnionFind():
    def __init__(self, n):
        self.n = n
        self.parents = [-1] * n

    def find(self, x):
        if self.parents[x] < 0:
            return x
        else:
            self.parents[x] = self.find(self.parents[x])
            return self.parents[x]

    def union(self, x, y):
        x = self.find(x)
        y = self.find(y)

        if x == y:
            return

        if self.parents[x] > self.parents[y]:
            x, y = y, x

        self.parents[x] += self.parents[y]
        self.parents[y] = x

    def size(self, x):
        return -self.parents[self.find(x)]

    def same(self, x, y):
        return self.find(x) == self.find(y)

    def members(self, x):
        root = self.find(x)
        return [i for i in range(self.n) if self.find(i) == root]

    def roots(self):
        return [i for i, x in enumerate(self.parents) if x < 0]

    def group_count(self):
        return len(self.roots())

    def all_group_members(self):
        return {r: self.members(r) for r in self.roots()}

    def __str__(self):
        return '\n'.join('{}: {}'.format(r, self.members(r)) for r in self.roots())


n, m, k = list(map(int, input().split()))
from collections import defaultdict

fr_bl = defaultdict(set)
ans = [0] * n
uf = UnionFind(n+1)


for _ in range(1, m+1):
    a, b = list(map(int, input().split()))
    fr_bl[a].add(b)
    fr_bl[b].add(a)
    uf.union(a, b)
for _ in range(1, k+1):
    c, d = list(map(int, input().split()))
    fr_bl[c].add(d)
    fr_bl[d].add(c)


# print(fr_bl)
# print(uf)

for i in range(1, n+1):
    # fr_bl[i].add(i)
    # print(i, set(uf.members(i)))
    # print(i, fr_bl[i])
    # print(i, set(uf.members(i)) - fr_bl[i])
    ans[i-1] = len(set(uf.members(i)) - fr_bl[i]) - 1


print((" ".join([str(i) for i in ans])))