Pagini recente » Cod sursa (job #2199214) | Diferente pentru problema/matrita intre reviziile 2 si 42 | Cod sursa (job #2483544) | Cod sursa (job #2264371) | Cod sursa (job #1401039)
# include <fstream>
# include <algorithm>
using namespace std;
ifstream f("xerox.in");
ofstream g("xerox.out");
int i,j,n,m,x,XOR,T;
int main ()
{
f>>T;
for (int t=1; t<=T; ++t)
{
f>>n>>x>>x;
XOR=0;
for (j=1; j<=n; ++j)
{
f>>x; XOR^=x;
for (int o=1; o<=2*n; ++o)
f>>x;
}
if (XOR) g<<"1\n";
else g<<"0\n";
}
return 0;
}