Union of Two Arrays


Submit solution

Points: 100
Time limit: 2.0s
Memory limit: 256M

Author:
Problem types

Find the set union of two integer arrays.

Input

The first line contains n and m. The next two lines contain arrays A and B.

Array and query counts are between $1$ and $10^5$. Integer values are between $-10^9$ and $10^9$. Deleting a missing multiset value has no effect.

Output

Print the distinct values in A union B in decreasing order.

Example

Input
5 5
1 2 3 4 5
3 4 5 6 7
Output
7 6 5 4 3 2 1

Comments

There are no comments at the moment.