Cod sursa(job #2290966)

Utilizator radugheoRadu Mihai Gheorghe radugheo Data 27 noiembrie 2018 11:17:01
Problema Xerox Scor 100
Compilator cpp-64 Status done
Runda Arhiva de probleme Marime 0.39 kb
#include <fstream>

using namespace std;

ifstream fin ("xerox.in");
ofstream fout ("xerox.out");

int i, n, sol, x, t, j, dx, dy, a, b;

int main(){
	fin >> t;
	for (j=1; j<=t; j++){
		fin >> n >> dx >> dy;
		sol = 0;
		for (i=1; i<=n; i++){
			fin >> x;
			sol ^= x;
			for (int k=1; k<=x; k++){
				fin >> a >> b;
			}
		}
		if (sol == 0)
			fout << "0\n";
		else
			fout << "1\n";
	}
	return 0;
}