1 / 6
Oct 2012

#include <iostream>
using namespace std;
int main()
{
	long int n;
	cin >> n;
    for ( long int i = 0; i < n; i++ ) {
	long int x,y;
	cin >> x;
	cin >> y;
	
	if (x == 0 && y == 0 ) {
		cout << x << endl;
	}
	else if (x%2 == 0 && y == 0 ) {
		cout << x+y << endl;
	}
	else if ( x%2 == 0 &&  y%2 == 0 ) {
		cout << x+y << endl;
	}
	else if ( x%2 != 0 && y%2 != 0 ) {
		cout << (x+y)-1 << endl;
	}
	else {
		cout << "No Number\n";
	}
}
return 0;
}

You have not tested very thoroughly. In fact you likely have not tested very much at all.