Cod sursa(job #1478351)
Utilizator | Data | 28 august 2015 14:29:28 | |
---|---|---|---|
Problema | ChatNoir | Scor | 100 |
Compilator | cpp | Status | done |
Runda | Arhiva de probleme | Marime | 0.37 kb |
#include <fstream>
#include <algorithm>
using namespace std;
ifstream in("chatnoir.in");
ofstream out("chatnoir.out");
int main() {
int testCase, n, m, x, y;
in >> testCase;
while(testCase--) {
in >> n >> m >> x >> y;
if(min(min(x, n-x+1), min(y, m-y+1)) <= 5) out << "DA\n";
else out << "NU\n";
}
return 0;
}