Cod sursa(job #638488)
Utilizator | UAIC.VlasCatalin ctlin04 | Data | 20 noiembrie 2011 21:52:17 |
---|---|---|---|
Problema | ChatNoir | Scor | 100 |
Compilator | fpc | Status | done |
Runda | Arhiva de probleme | Marime | 0.5 kb |
Program chatnoir;
var m,n,x,y,i,t:longint;
b1,b2:array [1..1 shl 15] of char;
fi,fo:text;
begin
assign(fi,'chatnoir.in');
assign(fo,'chatnoir.out');
settextbuf(fi,b1);
settextbuf(fo,b2);
reset(fi); rewrite(fo);
readln(fi,t);
for i:=1 to t do begin
readln(fi,n,m,x,y);
if (n-x<=4) or (m-y<=4) or (x<=5) or (y<=5) then writeln(fo,'DA')
else writeln(fo,'NU');
end;
close(fo);
end.