Vitaliy, like his friend Vasylko, has decided to explore bitwise operations. He randomly selects numbers: a_1, a_2, \ldots, a_N, and begins his experiments on this sequence. The process of these experiments is as follows: he repeatedly asks Vasylko to choose two numbers and , where 1 \leq x, y \leq N, and then he updates the element a_x to the value a_x \,\text{XOR}\, a_y.
After completing all these experiments, he calculates the sum of all elements in the sequence. What is the maximum sum he can achieve?
The first line contains the number , where 1 \leq N \leq 200.
The second line contains numbers: a_1, a_2, \ldots, a_N, with each a_i satisfying 1 \leq a_i \leq 10^{15}, and 1 \leq i \leq N.
Output a single number, which is the maximum possible sum of the sequence that Vitaliy can achieve after his experiments.
Example 1