#include
#include
using namespace std;
int main(int argc, char* argv[])
{
//ifstream cin("F:\\test.txt");
int count;
cin >> count;
for (int i = 0; i < count; i++)
{
int x, y, num = 0;
cin >> x >> y;
if (x != y && y != x - 2)
cout << "No Number" << endl;
else
{
if (x % 2 == 0 && y % 2 == 0)
num = x + y;
else if (x % 2 != 0 && y % 2 != 0)
num = x + y - 1;
cout << num << endl;
}
}
return 0;
}
ZOJ1414题的解法
最新推荐文章于 2020-09-25 20:11:55 发布