问题 CA: A与B与编译错误

内存限制:128 MB 时间限制:1 S
题面:传统 评测方式:文本比较 上传者:
提交:114 通过:79

题目描述


AB正在准备即将到来的信息学全国联赛。
B非常喜欢写程序。写完程序以后,他必须先编译代码。最初,编译器显示有n个编译错误,其中每一个被表示为一个正整数。经过一番努力,B设法解决一个错误,然后又编译了下,又改正了一个错误。B可以完全肯定,他纠正了两个错误,但他忘记了是哪几个编译错误消失了。 你能帮助B来找出那两个已经被改正的错误么?
A and B are preparing themselves for programming contests.
B loves to debug his code. But before he runs the solution and starts debugging, he has to first compile the code.
Initially, the compiler displayed n compilation errors, each of them is represented as a positive integer. After some effort, B managed to fix some mistake and then another one mistake.
However, despite the fact that B is sure that he corrected the two errors, he can not understand exactly what compilation errors disappeared − the compiler of the language which B uses shows errors in the new order every time! B is sure that unlike many other programming languages, compilation errors for his programming language do not depend on each other, that is, if you correct one error, the set of other error does not change.
Can you help B find out exactly what two errors he corrected?

Input
The first line of the input contains integer n (3≤n≤105) − the initial number of compilation errors.
The second line contains n space-separated integers a1,a2,...,an (1≤ai≤109) − the errors the compiler displayed for the first time.
The third line contains n-1 space-separated integers b1,b2,...,bn-1 − the errors displayed at the second compilation. It is guaranteed that the sequence in the third line contains all numbers of the second string except for exactly one.
The fourth line contains n-2 space-separated integers c1,c2,...,cn-2 − the errors displayed at the third compilation. It is guaranteed that the sequence in the fourth line contains all numbers of the third line except for exactly one.
Output
Print two numbers on a single line: the numbers of the compilation errors that disappeared after B made the first and the second correction, respectively.
Examples
Input
5
1 5 8 123 7
123 7 5 1
5 1 7
Output
8
123
Input
6
1 4 3 3 5 7
3 7 5 4 3
4 3 7 5
Output
1
3
Note
In the first test sample B first corrects the error number 8, then the error number 123.
In the second test sample B first corrects the error number 1, then the error number 3. Note that if there are multiple errors with the same number, B can correct only one of them in one step.



输入格式

输入的第一行包含整数n(3≤n≤10^ 5) - 表示编译错误的初始数量。

第二行包含n个空格分隔的整数a1,a2,...,an(1≤ai≤10^9),表示第一次编译的时候出现的n个编译错误的序号。

第三行包含n-1个空格分开的整数b1,b2,......,bn-1,表示改正了一个错误以后,第二次编译中显示的错误。保证第三行中的所有数字都是第二行中的所有数字,除了一个被改正了的错误。

第四行有n-2空格分开的整数c1, c2,..., cn-2,表示在又改正了一个错误之后,第三次编译显示的错误。保证在第四行的所有数字都是来自第三行的,除了被改正的那个错误。

输出格式

输出只有两行,第一行输出一个整数,表示第一次被改正的错误的序号,第二行也输出一个整数,表示第二次被改正的错误的序号。题目保证输入数据都是正确的。



Examples
Input
5
1 5 8 123 7
123 7 5 1
5 1 7
Output
8
123
Input
6
1 4 3 3 5 7
3 7 5 4 3
4 3 7 5
Output
1
3

输入样例 复制

5
1 5 8 123 7
123 7 5 1
5 1 7

输出样例 复制

8
123

数据范围与提示

在第一个样例中,B首先纠正了第8个错误,然后纠正了第123个.
在第二个样例中,B首先纠正了第1个错误,然后是第3个。
注意,如果有多个错误拥有相同的编号,B一次只能改正一个。