using System;
using static System.Console;
using System.Collections.Generic;
using System.Text;

namespace abc157
{
    class Program
    {
        static void Main()
        {
            var nmk = ReadLine().Split(' ');
            var n = int.Parse(nmk[0]);
            var m = int.Parse(nmk[1]);
            var k = int.Parse(nmk[2]);
            var friends = new int[m][];
            var blocks = new int[k][];
            for (var q = 0; q < m; ++q)
            {
                friends[q] = ReadNumList();
            }
            for (var q = 0; q < k; ++q)
            {
                blocks[q] = ReadNumList();
            }
            WriteLine(FSMain(n, friends, blocks));
        }
        static string FSMain(int n, int[][] friends, int[][] blocks)
        {
            var fTable = new HashSet<int>[n + 1];
            var bTable = new HashSet<int>[n + 1];
            for (var i = 1; i <= n; ++i)
            {
                fTable[i] = new HashSet<int>();
                bTable[i] = new HashSet<int>();
            }
            for (var q = 0; q < friends.Length; ++q)
            {
                fTable[friends[q][0]].Add(friends[q][1]);
                fTable[friends[q][1]].Add(friends[q][0]);
            }
            for (var q = 0; q < blocks.Length; ++q)
            {
                bTable[blocks[q][0]].Add(blocks[q][1]);
                bTable[blocks[q][1]].Add(blocks[q][0]);
            }

            var friendListTable = new List<int>[n + 1];
            for (var i = 1; i <= n; ++i)
            {
                if (friendListTable[i] == null)
                {
                    var fl = GetFriendList(i, fTable);
                    friendListTable[i] = fl;
                    foreach (var f in fl)
                    {
                        friendListTable[f] = fl;
                    }
                }
            }

            var sb = new StringBuilder();
            for (var i = 1; i <= n; ++i)
            {
                var total = friendListTable[i].Count - fTable[i].Count - 1;
                foreach (var b in bTable[i])
                {
                    if (friendListTable[i] == friendListTable[b])
                    {
                        --total;
                    }
                }
                sb.Append(total);
                if (i < n)
                {
                    sb.Append(" ");
                }
            }
            return sb.ToString();
        }
        static List<int> GetFriendList(int k, HashSet<int>[] ftree)
        {
            var q = new Queue<int>();
            q.Enqueue(k);
            var set = new HashSet<int>(){ k };
            while (q.Count > 0)
            {
                var i = q.Dequeue();
                if (ftree[i] != null)
                {
                    foreach (var friend in ftree[i])
                    {
                        if (!set.Contains(friend))
                        {
                            q.Enqueue(friend);
                            set.Add(friend);
                        }
                    }
                }
            }
            return new List<int>(set);
        }
        static int[] ReadNumList()
        {
            var line = Console.ReadLine().Split(' ');
            if (line.Length == 1 && string.IsNullOrEmpty(line[0]))
            {
                return new int[0];
            }
            var numList = new int[line.Length];
            for (var i = 0; i < line.Length; ++i)
            {
                numList[i] = int.Parse(line[i]);
            }
            return numList;
        }
    }
}


Measured memory_bytes: 91440