XOR#3084

XOR

1 secondo
128 megabyte
Difficile

The team of famous cryptoanalyst Professor Ksor is working on breaking the new Homogeneous Reducible Encryption Network. After extensive investigation, the problem of breaking the network was reduced to the following task.

Given several integer numbers a_1, a_2, \ldots, a_n, represent them in binary notation by prepending leading zeroes to the smaller numbers so that all have the same number of digits as the largest one. Rearrange the bits in each number to obtain new numbers b_1, b_2, \ldots, b_n, such that b_1 xor b_2 xor xor b_n = 0. Here xor means bitwise exclusive or.

As a new member of the professor's team, you have been assigned to solve this problem.

Input

The first line contains (2 \leq n \leq 50). The second line contains a_1, a_2, \ldots, a_n (1 \leq a_i \leq 10^{18}).

Output

Output b_1, b_2, \ldots, b_n. If there is no solution, output "impossible".

Esempi

Esempio 1

Loading
Loading

Esempio 2

Loading
Loading

Nota

In the first example, a_1 = 7 = 0111_2, a_2 = 10 = 1010_2, a_3 = 11 = 1011_2. If we rearrange bits to get b_1 = 7 = 0111_2, b_2 = 12 = 1100_2, b_3 = 11 = 1011_2, then b_1 xor b_2 xor b_3 = 0.