Pagini recente » Cod sursa (job #845518) | Cod sursa (job #1165717) | Cod sursa (job #3214731) | Cod sursa (job #2454490) | Cod sursa (job #43568)
Cod sursa(job #43568)
var n,m,l,h,a,b,nr,i,j,c,d:longint;
x,y:array[1..50001]of longint;
g,f:text;
e:boolean;
begin
assign(f,'ograzi.in');
reset(f);
readln(f,n,m,l,h);
for i:=1 to n do readln(f,x[i],y[i]);
n:=n+1;
l:=l+1;
h:=h+1;
for i:=1 to m do begin
readln(f,a,b);
x[n]:=a;
y[n]:=b;
j:=0;
e:=true;
while e do begin
j:=j+1;
if a-x[j]>-1 then if b-y[j]>-1 then if a-x[j]<l then if b-x[j]<h then e:=false;
end;
if j<n then nr:=nr+1;
end;
assign(g,'ograzi.out');
rewrite(g);
write(g,nr);
close(g);
end.