3
1 2 3
3 2
2
 3
84 30 9
9 84
9
 4
1 5 7 8
1 5 7
1 5
 3
796067435 964699482 819602309
964699482 796067435
964699482
 10
460626451 802090732 277246428 661369649 388684428 784303821 376287098 656422756 9301599 25720377
277246428 388684428 661369649 460626451 656422756 802090732 9301599 784303821 376287098
376287098 802090732 388684428 9301599 656422756 784303821 460626451 277246428
 6
5 4 3 3 5 5
3 5 5 4 3
3 5 4 3
 3
168638990 939116221 323703261
168638990 323703261
168638990
 3
77 77 77
77 77
77
 3
374054998 726316780 902899520
902899520 726316780
726316780

1
3
 30
84
 8
7
 819602309
796067435
 25720377
661369649
 5
5
 939116221
323703261
 77
77
 374054998
902899520

import java.util.function.BiFunction;
import java.io.BufferedWriter;
import java.util.InputMismatchException;
import java.io.InputStream;
import java.util.HashMap;
import java.util.NoSuchElementException;
import java.util.Map;
import java.io.OutputStreamWriter;
import java.math.BigInteger;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.Writer;
import java.io.IOException;
import java.util.Set;

/**
 * Built using CHelper plug-in
 * Actual solution is at the top
 * @author PloadyFree
 */
public class Main {
    public static void main(String[] args) {
        InputStream inputStream = System.in;
        OutputStream outputStream = System.out;
        InputReader in = new InputReader(inputStream);
        OutputWriter out = new OutputWriter(outputStream);
        TaskB solver = new TaskB();
        solver.solve(1, in, out);
        out.close();
    }
}

class TaskB {
    public void solve(int testNumber, InputReader in, OutputWriter out) {
        int n = in.readInt();

        Map<Integer, Integer> m1 = new HashMap<>();
        Map<Integer, Integer> m2 = new HashMap<>();
        
        for (int i = 0; i < n; i++) {
            int k = in.readInt();
            m1.merge(k, 1, (a,b) -> a+b);
            m2.merge(k, 1, (a,b) -> a+b);
        }

        for (int i = 0; i < n-1; i++) {
            int k = in.readInt();
            m2.merge(k, -1, (a,b) -> a+b);
        }

        int first = 0;
        for (Map.Entry e : m2.entrySet()) {
            if (e.getValue().equals(1)) {
                first = (int)e.getKey();
                m1.merge(first, -1, (a,b) -> a+b);
                break;
            }
        }
        
        for (int i = 0; i < n-2; i++) {
            int k = in.readInt();
            m1.merge(k, -1, (a,b) -> a+b);
        }
        
        int second = 0;
        for (Map.Entry e : m1.entrySet()) {
            if (e.getValue().equals(1)) {
                second = (int)e.getKey();
                m1.merge(first, -1, (a,b) -> a+b);
                break;
            }
        }
        
        out.print(first + " " + second);


    }
}

class InputReader {

    private InputStream stream;
    private byte[] buf = new byte[1024];
    private int curChar;
    private int numChars;
    private SpaceCharFilter filter;

    public InputReader(InputStream stream) {
        this.stream = stream;
    }

    public int read() {
        if (numChars == -1)
            throw new InputMismatchException();
        if (curChar >= numChars) {
            curChar = 0;
            try {
                numChars = stream.read(buf);
            } catch (IOException e) {
                throw new InputMismatchException();
            }
            if (numChars <= 0)
                return -1;
        }
        return buf[curChar++];
    }

    public int readInt() {
        int c = read();
        while (isSpaceChar(c))
            c = read();
        int sgn = 1;
        if (c == '-') {
            sgn = -1;
            c = read();
        }
        int res = 0;
        do {
            if (c < '0' || c > '9')
                throw new InputMismatchException();
            res *= 10;
            res += c - '0';
            c = read();
        } while (!isSpaceChar(c));
        return res * sgn;
    }

    public boolean isSpaceChar(int c) {
        if (filter != null)
            return filter.isSpaceChar(c);
        return isWhitespace(c);
    }

    public static boolean isWhitespace(int c) {
        return c == ' ' || c == '\n' || c == '\r' || c == '\t' || c == -1;
    }

    public interface SpaceCharFilter {
        public boolean isSpaceChar(int ch);
    }
}

class OutputWriter {
    private final PrintWriter writer;

    public OutputWriter(OutputStream outputStream) {
        writer = new PrintWriter(new BufferedWriter(new OutputStreamWriter(outputStream)));
    }

    public void print(Object...objects) {
        for (int i = 0; i < objects.length; i++) {
            if (i != 0)
                writer.print(' ');
            writer.print(objects[i]);
        }
    }

    public void close() {
        writer.close();
    }

}
