| TSEC Round 1 (Div. 4) |
|---|
| Закончено |
You are given an array of $$$n$$$ integers (a1, a2, a3, ....... an)
You have to find the number of pairs such that a[i] xor a[j] = a[i]
First line has a single integer $$$t$$$, number of tests [1 <= $$$t$$$ <= 10]
First line of each test has a single integer $$$n$$$, size of array [1 <= $$$n$$$ <= 100]
Second line of each test has $$$n$$$ integers, the array elements [0 <= $$$a[i]$$$ <= 1e9]
It is guaranteed that sum of n among all tests do not exceed 100
For each test, print a single integer, the number of pairs
350 1 0 2 070 1 1 2 3 0 140 0 0 0
15 14 16
| Название |
|---|


