9077 - Advanced Heap Sort   

Description

Given two increasing sorted lists S1 and S2. Each has N integers. There are N*N sums composed of one element in S1 and the other element in S2. Please output the smallest N sums.

Input

The input includes multiple test cases. In each test case, the first line contains one integers N. The second line contains N integers and the third line also contains N integers.

Guarantee every element or every sum must be an integer.

1 <= N <= 105

Output

The one line contains the smallest N sums. They are separated by single space.

Sample Input  Download

Sample Output  Download

Tags




Discuss