# -*- coding: utf-8 -*-
import sys
import math
import os
import itertools
import string
import heapq
import _collections
from collections import Counter
from collections import defaultdict
from collections import deque
from functools import lru_cache
import bisect
import re
import queue
import decimal


class Scanner():
    @staticmethod
    def int():
        return int(sys.stdin.readline().rstrip())

    @staticmethod
    def string():
        return sys.stdin.readline().rstrip()

    @staticmethod
    def map_int():
        return [int(x) for x in Scanner.string().split()]

    @staticmethod
    def string_list(n):
        return [Scanner.string() for i in range(n)]

    @staticmethod
    def int_list_list(n):
        return [Scanner.map_int() for i in range(n)]

    @staticmethod
    def int_cols_list(n):
        return [Scanner.int() for i in range(n)]


class Math():
    @staticmethod
    def gcd(a, b):
        if b == 0:
            return a
        return Math.gcd(b, a % b)

    @staticmethod
    def lcm(a, b):
        return (a * b) // Math.gcd(a, b)

    @staticmethod
    def divisor(n):
        res = []
        i = 1
        for i in range(1, int(n ** 0.5) + 1):
            if n % i == 0:
                res.append(i)
                if i != n // i:
                    res.append(n // i)
        return res

    @staticmethod
    def round_up(a, b):
        return -(-a // b)

    @staticmethod
    def is_prime(n):
        if n < 2:
            return False
        if n == 2:
            return True
        if n % 2 == 0:
            return False
        d = int(n ** 0.5) + 1
        for i in range(3, d + 1, 2):
            if n % i == 0:
                return False
        return True

    @staticmethod
    def fact(N):
        res = {}
        tmp = N
        for i in range(2, int(N ** 0.5 + 1) + 1):
            cnt = 0
            while tmp % i == 0:
                cnt += 1
                tmp //= i
            if cnt > 0:
                res[i] = cnt
        if tmp != 1:
            res[tmp] = 1
        if res == {}:
            res[N] = 1
        return res


def pop_count(x):
    x = x - ((x >> 1) & 0x5555555555555555)
    x = (x & 0x3333333333333333) + ((x >> 2) & 0x3333333333333333)
    x = (x + (x >> 4)) & 0x0f0f0f0f0f0f0f0f
    x = x + (x >> 8)
    x = x + (x >> 16)
    x = x + (x >> 32)
    return x & 0x0000007f


MOD = int(1e09) + 7
INF = int(1e15)


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

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

    def unite(self, x, y):
        x = self.root(x)
        y = self.root(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.root(x)]

    def is_same(self, x, y):
        return self.root(x) == self.root(y)


def solve():
    N, M, K = Scanner.map_int()
    uni = UnionFind(N)
    friends = [set() for _ in range(N)]
    for _ in range(M):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        uni.unite(a, b)
        friends[a].add(b)
        friends[b].add(a)
    block = [set() for _ in range(N)]
    for _ in range(K):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        block[a].add(b)
        block[b].add(a)
    ans = [0 for _ in range(N)]
    for i in range(N):
        size = uni.size(i)
        f = len(friends[i])
        bn = 0
        for b in block[i]:
            if uni.is_same(i, b):
                bn += 1
        ans[i] = size - 1 - f - bn
    print(*ans)


def main():
    # sys.stdin = open("sample.txt")
    # T = Scanner.int()
    # for _ in range(T):
    #     solve()
    # print('YNeos'[not solve()::2])
    solve()


if __name__ == "__main__":
    main() import sys sys import math math import os os import itertools itertools import string string import heapq heapq import _collections _collections from collections import Counter from collections import defaultdict from collections import deque from functools import lru_cache import bisect bisect import re re import queue queue import decimal decimal class Scanner():
    @staticmethod
    def int():
        return int(sys.stdin.readline().rstrip())

    @staticmethod
    def string():
        return sys.stdin.readline().rstrip()

    @staticmethod
    def map_int():
        return [int(x) for x in Scanner.string().split()]

    @staticmethod
    def string_list(n):
        return [Scanner.string() for i in range(n)]

    @staticmethod
    def int_list_list(n):
        return [Scanner.map_int() for i in range(n)]

    @staticmethod
    def int_cols_list(n):
        return [Scanner.int() for i in range(n)] Scanner def int():
        return int(sys.stdin.readline().rstrip())

     int return int(sys.stdin.readline().rstrip()) int(sys.stdin.readline().rstrip()) int sys.stdin.readline().rstrip() sys.stdin.readline().rstrip sys.stdin.readline() sys.stdin.readline sys.stdin sys stdin readline rstrip @staticmethod
     int staticmethod int def string():
        return sys.stdin.readline().rstrip()

     string return sys.stdin.readline().rstrip() sys.stdin.readline().rstrip() sys.stdin.readline().rstrip sys.stdin.readline() sys.stdin.readline sys.stdin sys stdin readline rstrip @staticmethod
     string staticmethod string def map_int():
        return [int(x) for x in Scanner.string().split()]

     map_int int(x) for x in Scanner.string().split() for x in Scanner.string().split() x Scanner.string().split() Scanner.string().split Scanner.string() Scanner.string Scanner string split for x in Scanner.string().split() int(x) int x return [int(x) for x in Scanner.string().split()] [int(x) for x in Scanner.string().split()] @staticmethod
     map_int staticmethod map_int def string_list(n):
        return [Scanner.string() for i in range(n)]

     string_list Scanner.string() for i in range(n) for i in range(n) i range(n) range n for i in range(n) Scanner.string() Scanner.string Scanner string return [Scanner.string() for i in range(n)] [Scanner.string() for i in range(n)] n n @staticmethod
     string_list staticmethod string_list def int_list_list(n):
        return [Scanner.map_int() for i in range(n)]

     int_list_list Scanner.map_int() for i in range(n) for i in range(n) i range(n) range n for i in range(n) Scanner.map_int() Scanner.map_int Scanner map_int return [Scanner.map_int() for i in range(n)] [Scanner.map_int() for i in range(n)] n n @staticmethod
     int_list_list staticmethod int_list_list def int_cols_list(n):
        return [Scanner.int() for i in range(n)] int_cols_list Scanner.int() for i in range(n) for i in range(n) i range(n) range n for i in range(n) Scanner.int() Scanner.int Scanner int return [Scanner.int() for i in range(n)] [Scanner.int() for i in range(n)] n n @staticmethod
     int_cols_list staticmethod int_cols_list class Math():
    @staticmethod
    def gcd(a, b):
        if b == 0:
            return a
        return Math.gcd(b, a % b)

    @staticmethod
    def lcm(a, b):
        return (a * b) // Math.gcd(a, b)

    @staticmethod
    def divisor(n):
        res = []
        i = 1
        for i in range(1, int(n ** 0.5) + 1):
            if n % i == 0:
                res.append(i)
                if i != n // i:
                    res.append(n // i)
        return res

    @staticmethod
    def round_up(a, b):
        return -(-a // b)

    @staticmethod
    def is_prime(n):
        if n < 2:
            return False
        if n == 2:
            return True
        if n % 2 == 0:
            return False
        d = int(n ** 0.5) + 1
        for i in range(3, d + 1, 2):
            if n % i == 0:
                return False
        return True

    @staticmethod
    def fact(N):
        res = {}
        tmp = N
        for i in range(2, int(N ** 0.5 + 1) + 1):
            cnt = 0
            while tmp % i == 0:
                cnt += 1
                tmp //= i
            if cnt > 0:
                res[i] = cnt
        if tmp != 1:
            res[tmp] = 1
        if res == {}:
            res[N] = 1
        return res Math def gcd(a, b):
        if b == 0:
            return a
        return Math.gcd(b, a % b)

     gcd if b == 0:
            return a
         b == 0 b 0 return a a return Math.gcd(b, a % b) Math.gcd(b, a % b) Math.gcd Math gcd b a % b a b a a b b @staticmethod
     gcd staticmethod gcd def lcm(a, b):
        return (a * b) // Math.gcd(a, b)

     lcm return (a * b) // Math.gcd(a, b) (a * b) // Math.gcd(a, b) a * b a b Math.gcd(a, b) Math.gcd Math gcd a b a a b b @staticmethod
     lcm staticmethod lcm def divisor(n):
        res = []
        i = 1
        for i in range(1, int(n ** 0.5) + 1):
            if n % i == 0:
                res.append(i)
                if i != n // i:
                    res.append(n // i)
        return res

     divisor res = [] res [] i = 1 i 1 for i in range(1, int(n ** 0.5) + 1):
            if n % i == 0:
                res.append(i)
                if i != n // i:
                    res.append(n // i)
         i range(1, int(n ** 0.5) + 1) range 1 int(n ** 0.5) + 1 int(n ** 0.5) int n ** 0.5 n 0.5 1 if n % i == 0:
                res.append(i)
                if i != n // i:
                    res.append(n // i)
         n % i == 0 n % i n i 0 res.append(i) res.append res append i if i != n // i:
                    res.append(n // i)
         i != n // i i n // i n i res.append(n // i) res.append res append n // i n i return res res n n @staticmethod
     divisor staticmethod divisor def round_up(a, b):
        return -(-a // b)

     round_up return -(-a // b) -(-a // b) -a // b -a a b a a b b @staticmethod
     round_up staticmethod round_up def is_prime(n):
        if n < 2:
            return False
        if n == 2:
            return True
        if n % 2 == 0:
            return False
        d = int(n ** 0.5) + 1
        for i in range(3, d + 1, 2):
            if n % i == 0:
                return False
        return True

     is_prime if n < 2:
            return False
         n < 2 n 2 return False False if n == 2:
            return True
         n == 2 n 2 return True True if n % 2 == 0:
            return False
         n % 2 == 0 n % 2 n 2 0 return False False d = int(n ** 0.5) + 1 d int(n ** 0.5) + 1 int(n ** 0.5) int n ** 0.5 n 0.5 1 for i in range(3, d + 1, 2):
            if n % i == 0:
                return False
         i range(3, d + 1, 2) range 3 d + 1 d 1 2 if n % i == 0:
                return False
         n % i == 0 n % i n i 0 return False False return True True n n @staticmethod
     is_prime staticmethod is_prime def fact(N):
        res = {}
        tmp = N
        for i in range(2, int(N ** 0.5 + 1) + 1):
            cnt = 0
            while tmp % i == 0:
                cnt += 1
                tmp //= i
            if cnt > 0:
                res[i] = cnt
        if tmp != 1:
            res[tmp] = 1
        if res == {}:
            res[N] = 1
        return res fact res = {} res {} tmp = N tmp N for i in range(2, int(N ** 0.5 + 1) + 1):
            cnt = 0
            while tmp % i == 0:
                cnt += 1
                tmp //= i
            if cnt > 0:
                res[i] = cnt
         i range(2, int(N ** 0.5 + 1) + 1) range 2 int(N ** 0.5 + 1) + 1 int(N ** 0.5 + 1) int N ** 0.5 + 1 N ** 0.5 N 0.5 1 1 cnt = 0 cnt 0 while tmp % i == 0:
                cnt += 1
                tmp //= i
             tmp % i == 0 tmp % i tmp i 0 cnt += 1 cnt 1 tmp //= i tmp i if cnt > 0:
                res[i] = cnt
         cnt > 0 cnt 0 res[i] = cnt res[i] res i cnt if tmp != 1:
            res[tmp] = 1
         tmp != 1 tmp 1 res[tmp] = 1 res[tmp] res tmp 1 if res == {}:
            res[N] = 1
         res == {} res {} res[N] = 1 res[N] res N 1 return res res N N @staticmethod
     fact staticmethod fact def pop_count(x):
    x = x - ((x >> 1) & 0x5555555555555555)
    x = (x & 0x3333333333333333) + ((x >> 2) & 0x3333333333333333)
    x = (x + (x >> 4)) & 0x0f0f0f0f0f0f0f0f
    x = x + (x >> 8)
    x = x + (x >> 16)
    x = x + (x >> 32)
    return x & 0x0000007f pop_count x = x - ((x >> 1) & 0x5555555555555555) x x - ((x >> 1) & 0x5555555555555555) x (x >> 1) & 0x5555555555555555 x >> 1 x 1 0x5555555555555555 x = (x & 0x3333333333333333) + ((x >> 2) & 0x3333333333333333) x (x & 0x3333333333333333) + ((x >> 2) & 0x3333333333333333) x & 0x3333333333333333 x 0x3333333333333333 (x >> 2) & 0x3333333333333333 x >> 2 x 2 0x3333333333333333 x = (x + (x >> 4)) & 0x0f0f0f0f0f0f0f0f x (x + (x >> 4)) & 0x0f0f0f0f0f0f0f0f x + (x >> 4) x x >> 4 x 4 0x0f0f0f0f0f0f0f0f x = x + (x >> 8) x x + (x >> 8) x x >> 8 x 8 x = x + (x >> 16) x x + (x >> 16) x x >> 16 x 16 x = x + (x >> 32) x x + (x >> 32) x x >> 32 x 32 return x & 0x0000007f x & 0x0000007f x 0x0000007f x x MOD = int(1e09) + 7 MOD int(1e09) + 7 int(1e09) int 1e09 7 INF = int(1e15) INF int(1e15) int 1e15 class UnionFind:
    def __init__(self, n):
        self.n = n
        self.parents = [-1] * n

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

    def unite(self, x, y):
        x = self.root(x)
        y = self.root(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.root(x)]

    def is_same(self, x, y):
        return self.root(x) == self.root(y) UnionFind def __init__(self, n):
        self.n = n
        self.parents = [-1] * n

     __init__ self.n = n self.n self n n self.parents = [-1] * n self.parents self parents [-1] * n [-1] -1 n self self n n def root(self, x):
        if self.parents[x] < 0:
            return x
        else:
            self.parents[x] = self.root(self.parents[x])
            return self.parents[x]

     root if self.parents[x] < 0:
            return x
        else:
            self.parents[x] = self.root(self.parents[x])
            return self.parents[x]

     self.parents[x] < 0 self.parents[x] self.parents self parents x 0 return x x self.parents[x] = self.root(self.parents[x]) self.parents[x] self.parents self parents x self.root(self.parents[x]) self.root self root self.parents[x] self.parents self parents x return self.parents[x] self.parents[x] self.parents self parents x self self x x def unite(self, x, y):
        x = self.root(x)
        y = self.root(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

     unite x = self.root(x) x self.root(x) self.root self root x y = self.root(y) y self.root(y) self.root self root y if x == y:
            return
         x == y x y return if self.parents[x] > self.parents[y]:
            x, y = y, x
         self.parents[x] > self.parents[y] self.parents[x] self.parents self parents x self.parents[y] self.parents self parents y x, y = y, x x y y x self.parents[x] += self.parents[y] self.parents[x] self.parents self parents x self.parents[y] self.parents self parents y self.parents[y] = x self.parents[y] self.parents self parents y x self self x x y y def size(self, x):
        return -self.parents[self.root(x)]

     size return -self.parents[self.root(x)] -self.parents[self.root(x)] self.parents[self.root(x)] self.parents self parents self.root(x) self.root self root x self self x x def is_same(self, x, y):
        return self.root(x) == self.root(y) is_same return self.root(x) == self.root(y) self.root(x) == self.root(y) self.root(x) self.root self root x self.root(y) self.root self root y self self x x y y def solve():
    N, M, K = Scanner.map_int()
    uni = UnionFind(N)
    friends = [set() for _ in range(N)]
    for _ in range(M):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        uni.unite(a, b)
        friends[a].add(b)
        friends[b].add(a)
    block = [set() for _ in range(N)]
    for _ in range(K):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        block[a].add(b)
        block[b].add(a)
    ans = [0 for _ in range(N)]
    for i in range(N):
        size = uni.size(i)
        f = len(friends[i])
        bn = 0
        for b in block[i]:
            if uni.is_same(i, b):
                bn += 1
        ans[i] = size - 1 - f - bn
    print(*ans) solve N, M, K = Scanner.map_int() N Scanner.map_int() Scanner.map_int Scanner map_int M K uni = UnionFind(N) uni UnionFind(N) UnionFind N set() for _ in range(N) for _ in range(N) _ range(N) range N for _ in range(N) set() set friends = [set() for _ in range(N)] friends [set() for _ in range(N)] for _ in range(M):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        uni.unite(a, b)
        friends[a].add(b)
        friends[b].add(a)
     _ range(M) range M a, b = Scanner.map_int() a Scanner.map_int() Scanner.map_int Scanner map_int b a -= 1 a 1 b -= 1 b 1 uni.unite(a, b) uni.unite uni unite a b friends[a].add(b) [a].add [a] friends a add b friends[b].add(a) [b].add [b] friends b add a set() for _ in range(N) for _ in range(N) _ range(N) range N for _ in range(N) set() set block = [set() for _ in range(N)] block [set() for _ in range(N)] for _ in range(K):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        block[a].add(b)
        block[b].add(a)
     _ range(K) range K a, b = Scanner.map_int() a Scanner.map_int() Scanner.map_int Scanner map_int b a -= 1 a 1 b -= 1 b 1 block[a].add(b) [a].add [a] block a add b block[b].add(a) [b].add [b] block b add a 0 for _ in range(N) for _ in range(N) _ range(N) range N for _ in range(N) 0 ans = [0 for _ in range(N)] ans [0 for _ in range(N)] for i in range(N):
        size = uni.size(i)
        f = len(friends[i])
        bn = 0
        for b in block[i]:
            if uni.is_same(i, b):
                bn += 1
        ans[i] = size - 1 - f - bn
     i range(N) range N size = uni.size(i) size uni.size(i) uni.size uni size i f = len(friends[i]) f len(friends[i]) len friends[i] friends i bn = 0 bn 0 for b in block[i]:
            if uni.is_same(i, b):
                bn += 1
         b block[i] block i if uni.is_same(i, b):
                bn += 1
         uni.is_same(i, b) uni.is_same uni is_same i b bn += 1 bn 1 ans[i] = size - 1 - f - bn ans[i] ans i size - 1 - f - bn size - 1 - f size - 1 size 1 f bn print(*ans) print *ans ans def main():
    # sys.stdin = open("sample.txt")
    # T = Scanner.int()
    # for _ in range(T):
    #     solve()
    # print('YNeos'[not solve()::2])
    solve() main solve() solve if __name__ == "__main__":
    main() __name__ == "__main__" __name__ "__main__" main() main class UnionFind:
    def __init__(self, n):
        self.n = n
        self.parents = [-1] * n

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

    def unite(self, x, y):
        x = self.root(x)
        y = self.root(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.root(x)]

    def is_same(self, x, y):
        return self.root(x) == self.root(y) class UnionFind:
    def __init__(self, n):
        self.n = n
        self.parents = [-1] * n

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

    def unite(self, x, y):
        x = self.root(x)
        y = self.root(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.root(x)]

    def is_same(self, x, y):
        return self.root(x) == self.root(y) UnionFind def pop_count(x):
    x = x - ((x >> 1) & 0x5555555555555555)
    x = (x & 0x3333333333333333) + ((x >> 2) & 0x3333333333333333)
    x = (x + (x >> 4)) & 0x0f0f0f0f0f0f0f0f
    x = x + (x >> 8)
    x = x + (x >> 16)
    x = x + (x >> 32)
    return x & 0x0000007f def pop_count(x):
    x = x - ((x >> 1) & 0x5555555555555555)
    x = (x & 0x3333333333333333) + ((x >> 2) & 0x3333333333333333)
    x = (x + (x >> 4)) & 0x0f0f0f0f0f0f0f0f
    x = x + (x >> 8)
    x = x + (x >> 16)
    x = x + (x >> 32)
    return x & 0x0000007f pop_count MOD = int(1e09) + 7 int(1e09) + 7 MOD class Math():
    @staticmethod
    def gcd(a, b):
        if b == 0:
            return a
        return Math.gcd(b, a % b)

    @staticmethod
    def lcm(a, b):
        return (a * b) // Math.gcd(a, b)

    @staticmethod
    def divisor(n):
        res = []
        i = 1
        for i in range(1, int(n ** 0.5) + 1):
            if n % i == 0:
                res.append(i)
                if i != n // i:
                    res.append(n // i)
        return res

    @staticmethod
    def round_up(a, b):
        return -(-a // b)

    @staticmethod
    def is_prime(n):
        if n < 2:
            return False
        if n == 2:
            return True
        if n % 2 == 0:
            return False
        d = int(n ** 0.5) + 1
        for i in range(3, d + 1, 2):
            if n % i == 0:
                return False
        return True

    @staticmethod
    def fact(N):
        res = {}
        tmp = N
        for i in range(2, int(N ** 0.5 + 1) + 1):
            cnt = 0
            while tmp % i == 0:
                cnt += 1
                tmp //= i
            if cnt > 0:
                res[i] = cnt
        if tmp != 1:
            res[tmp] = 1
        if res == {}:
            res[N] = 1
        return res class Math():
    @staticmethod
    def gcd(a, b):
        if b == 0:
            return a
        return Math.gcd(b, a % b)

    @staticmethod
    def lcm(a, b):
        return (a * b) // Math.gcd(a, b)

    @staticmethod
    def divisor(n):
        res = []
        i = 1
        for i in range(1, int(n ** 0.5) + 1):
            if n % i == 0:
                res.append(i)
                if i != n // i:
                    res.append(n // i)
        return res

    @staticmethod
    def round_up(a, b):
        return -(-a // b)

    @staticmethod
    def is_prime(n):
        if n < 2:
            return False
        if n == 2:
            return True
        if n % 2 == 0:
            return False
        d = int(n ** 0.5) + 1
        for i in range(3, d + 1, 2):
            if n % i == 0:
                return False
        return True

    @staticmethod
    def fact(N):
        res = {}
        tmp = N
        for i in range(2, int(N ** 0.5 + 1) + 1):
            cnt = 0
            while tmp % i == 0:
                cnt += 1
                tmp //= i
            if cnt > 0:
                res[i] = cnt
        if tmp != 1:
            res[tmp] = 1
        if res == {}:
            res[N] = 1
        return res Math def main():
    # sys.stdin = open("sample.txt")
    # T = Scanner.int()
    # for _ in range(T):
    #     solve()
    # print('YNeos'[not solve()::2])
    solve() def main():
    # sys.stdin = open("sample.txt")
    # T = Scanner.int()
    # for _ in range(T):
    #     solve()
    # print('YNeos'[not solve()::2])
    solve() main INF = int(1e15) int(1e15) INF def solve():
    N, M, K = Scanner.map_int()
    uni = UnionFind(N)
    friends = [set() for _ in range(N)]
    for _ in range(M):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        uni.unite(a, b)
        friends[a].add(b)
        friends[b].add(a)
    block = [set() for _ in range(N)]
    for _ in range(K):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        block[a].add(b)
        block[b].add(a)
    ans = [0 for _ in range(N)]
    for i in range(N):
        size = uni.size(i)
        f = len(friends[i])
        bn = 0
        for b in block[i]:
            if uni.is_same(i, b):
                bn += 1
        ans[i] = size - 1 - f - bn
    print(*ans) def solve():
    N, M, K = Scanner.map_int()
    uni = UnionFind(N)
    friends = [set() for _ in range(N)]
    for _ in range(M):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        uni.unite(a, b)
        friends[a].add(b)
        friends[b].add(a)
    block = [set() for _ in range(N)]
    for _ in range(K):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        block[a].add(b)
        block[b].add(a)
    ans = [0 for _ in range(N)]
    for i in range(N):
        size = uni.size(i)
        f = len(friends[i])
        bn = 0
        for b in block[i]:
            if uni.is_same(i, b):
                bn += 1
        ans[i] = size - 1 - f - bn
    print(*ans) solve class Scanner():
    @staticmethod
    def int():
        return int(sys.stdin.readline().rstrip())

    @staticmethod
    def string():
        return sys.stdin.readline().rstrip()

    @staticmethod
    def map_int():
        return [int(x) for x in Scanner.string().split()]

    @staticmethod
    def string_list(n):
        return [Scanner.string() for i in range(n)]

    @staticmethod
    def int_list_list(n):
        return [Scanner.map_int() for i in range(n)]

    @staticmethod
    def int_cols_list(n):
        return [Scanner.int() for i in range(n)] class Scanner():
    @staticmethod
    def int():
        return int(sys.stdin.readline().rstrip())

    @staticmethod
    def string():
        return sys.stdin.readline().rstrip()

    @staticmethod
    def map_int():
        return [int(x) for x in Scanner.string().split()]

    @staticmethod
    def string_list(n):
        return [Scanner.string() for i in range(n)]

    @staticmethod
    def int_list_list(n):
        return [Scanner.map_int() for i in range(n)]

    @staticmethod
    def int_cols_list(n):
        return [Scanner.int() for i in range(n)] Scanner
# -*- coding: utf-8 -*-
import sys
import math
import os
import itertools
import string
import heapq
import _collections
from collections import Counter
from collections import defaultdict
from collections import deque
from functools import lru_cache
import bisect
import re
import queue
import decimal


class Scanner():
    @staticmethod
    def int():
        return int(sys.stdin.readline().rstrip())

    @staticmethod
    def string():
        return sys.stdin.readline().rstrip()

    @staticmethod
    def map_int():
        return [int(x) for x in Scanner.string().split()]

    @staticmethod
    def string_list(n):
        return [Scanner.string() for i in range(n)]

    @staticmethod
    def int_list_list(n):
        return [Scanner.map_int() for i in range(n)]

    @staticmethod
    def int_cols_list(n):
        return [Scanner.int() for i in range(n)]


class Math():
    @staticmethod
    def gcd(a, b):
        if b == 0:
            return a
        return Math.gcd(b, a % b)

    @staticmethod
    def lcm(a, b):
        return (a * b) // Math.gcd(a, b)

    @staticmethod
    def divisor(n):
        res = []
        i = 1
        for i in range(1, int(n ** 0.5) + 1):
            if n % i == 0:
                res.append(i)
                if i != n // i:
                    res.append(n // i)
        return res

    @staticmethod
    def round_up(a, b):
        return -(-a // b)

    @staticmethod
    def is_prime(n):
        if n < 2:
            return False
        if n == 2:
            return True
        if n % 2 == 0:
            return False
        d = int(n ** 0.5) + 1
        for i in range(3, d + 1, 2):
            if n % i == 0:
                return False
        return True

    @staticmethod
    def fact(N):
        res = {}
        tmp = N
        for i in range(2, int(N ** 0.5 + 1) + 1):
            cnt = 0
            while tmp % i == 0:
                cnt += 1
                tmp //= i
            if cnt > 0:
                res[i] = cnt
        if tmp != 1:
            res[tmp] = 1
        if res == {}:
            res[N] = 1
        return res


def pop_count(x):
    x = x - ((x >> 1) & 0x5555555555555555)
    x = (x & 0x3333333333333333) + ((x >> 2) & 0x3333333333333333)
    x = (x + (x >> 4)) & 0x0f0f0f0f0f0f0f0f
    x = x + (x >> 8)
    x = x + (x >> 16)
    x = x + (x >> 32)
    return x & 0x0000007f


MOD = int(1e09) + 7
INF = int(1e15)


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

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

    def unite(self, x, y):
        x = self.root(x)
        y = self.root(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.root(x)]

    def is_same(self, x, y):
        return self.root(x) == self.root(y)


def solve():
    N, M, K = Scanner.map_int()
    uni = UnionFind(N)
    friends = [set() for _ in range(N)]
    for _ in range(M):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        uni.unite(a, b)
        friends[a].add(b)
        friends[b].add(a)
    block = [set() for _ in range(N)]
    for _ in range(K):
        a, b = Scanner.map_int()
        a -= 1
        b -= 1
        block[a].add(b)
        block[b].add(a)
    ans = [0 for _ in range(N)]
    for i in range(N):
        size = uni.size(i)
        f = len(friends[i])
        bn = 0
        for b in block[i]:
            if uni.is_same(i, b):
                bn += 1
        ans[i] = size - 1 - f - bn
    print(*ans)


def main():
    # sys.stdin = open("sample.txt")
    # T = Scanner.int()
    # for _ in range(T):
    #     solve()
    # print('YNeos'[not solve()::2])
    solve()


if __name__ == "__main__":
    main()
