#C4409. Unique Integers

    ID: 47944 Type: Default 1000ms 256MiB

Unique Integers

Unique Integers

You are given a list of integers. Your task is to print the integers that appear in the list in the same order as their first occurrence. In other words, remove the duplicates while preserving the order. The answer should be printed in a single line with the unique integers separated by spaces.

Input Format: The first line contains an integer \(n\) denoting the number of elements in the list. The second line contains \(n\) space-separated integers.

Output Format: Print the unique integers separated by a single space in the order of their first occurrence. If the list is empty, print nothing.

Example:

Input:
7
4 5 9 4 9 10 5

Output: 4 5 9 10

</p>

inputFormat

The input is read from standard input (stdin). The first line contains a single integer \(n\) — the number of elements in the list. The second line contains \(n\) space-separated integers.

outputFormat

The output, written to standard output (stdout), is a single line containing the unique integers separated by a single space, in the order of their first appearance.

## sample
7
4 5 9 4 9 10 5
4 5 9 10