Particle Arts
时间限制:C/C++/Rust/Pascal 1秒,其他语言2秒
空间限制:C/C++/Rust/Pascal 256 M,其他语言512 M
Special Judge, 64bit IO Format: %lld

题目描述

In a confined NIO space, there are n NIO particles, the i-th of which has a_i joule energy. The NIO particles are very special as they keep colliding with each other randomly. When one particle carrying energy a joule collides with another particle carrying energy b joule, they will be annihilated and produce two new particles carrying the energy of and respectively. Here and mean bitwise AND and OR operation respectively.

The variance of the energy of these particles is obviously not decreasing, but unfortunately, the space here is too small for the author to write down his proof. After enough time the variance of the energy of these particles converges to a stable value. Can you find this value?

The variance of n numbers is defined as follows.

输入描述:

The first line contains an integer n (), indicating the number of particles.

The second line contains n integers (), indicating the enegery of the particles.

输出描述:

Output a irreducible fraction  () in the form of  that represents the answer. You should ensure that  or when , b should be 1.
示例1

输入

复制
5
1 2 3 4 5

输出

复制
54/5

备注:

Warm tip: Please note the use of data types.