using namespace std;
int main()
{
int n,m,num,sum,flag;
int arr[8] = {0};
cin >> n;
for (int i = 0;i < n; i++)
{
num = 0;
sum = 0;
cin >> m;
int p[100];
int b[100] = {0};
for (int j = 0;j < m; j++)
{
cin >> p[j];
}
for (int k = 0;k < m; k++)
{
for (int x = 7;x >= 0; x--)
{
arr[x] = p[k] % 2;
p[k] /= 2;
}
int y = 1;
for (int x = 7;x >= 0; x--)
{
b[k] += arr[x] * y;
y *= 10;
}
}
for (int z = 0;z < m; z++)
{
if (z == 0)
num = b[z];
else
num = num ^ b[z];
}
flag = num ^ 0;
if (flag != 0)
cout << "yes" << endl;
else
cout << "no" << endl;
}
return 0;
}
沒有留言:
張貼留言