Cod sursa(job #1170182)
Utilizator | Data | 12 aprilie 2014 20:17:52 | |
---|---|---|---|
Problema | ChatNoir | Scor | 0 |
Compilator | cpp | Status | done |
Runda | Arhiva de probleme | Marime | 0.35 kb |
#include <iostream>
#include <fstream>
using namespace std;
int main()
{int a,m,n,x,y,i,ok;
fstream f("chatnoir.in");
ofstream g("chatnoir.out");
f>>a;
for(i=1;i<=a;i++)
{
ok=0;
f>>m;
f>>n;
f>>x;
f>>y;
if(x-1<=x-m) m=1;
if(y-1<=y-n) n=1;
if(x=y-m-n<4) ok=1;
if(ok=1) g<<"DA";
else g<<"NU";
}
}