Олимпиадный тренинг

Задача 43376. No more than two


Задача

Темы: Множества
Masha, Dasha and Misha collect cards with numbers. Each of them already has n cards. Each card has a number not exceeding 10. Are you interested in what numbers occur in no more than two of the guys?
Write a program to find the answer to this question.
 

Input data
The first line contains a natural number n - the number of cards each child has. Each of the following three lines contains n positive numbers, not exceeding 10, separated by a space. In the second line - the numbers on Masha's cards, in the third - Dasha, in the fourth - Misha.

Imprint data
Print one line - a set of numbers in ascending order, separated by spaces, which occur in no more than two of the guys.

 
Examples
# Input Output
1
4
0 8 9 5 
6 7 3 7 
4 3 5 5
0 3 4 5 6 7 8 9
2
3
1 2 3
1 2 3
4 5 6
1 2 3 4 5 6