Cod sursa(job #696959)
| Utilizator | Data | 28 februarie 2012 21:13:34 | |
|---|---|---|---|
| Problema | Xerox | Scor | 100 |
| Compilator | cpp | Status | done |
| Runda | Arhiva de probleme | Marime | 0.55 kb |
#include <iostream>
#include <cstdio>
#include <algorithm>
using namespace std;
int main()
{
freopen ("xerox.in", "r", stdin);
freopen ("xerox.out", "w", stdout);
int T;
scanf ("%d", &T);
while (T --)
{
int N, DX, DY;
int XorS = 0;
scanf ("%d %d %d", &N, &DX, &DY);
for (int i = 1; i <= N; ++ i)
{
int M;
scanf ("%d", &M);
for (int j = 1, a, b; j <= M; ++ j) scanf ("%d %d", &a, &b);
XorS ^= M;
}
if (XorS) printf ("1\n");
else printf ("0\n");
}
return 0;
}
