#include <stdio.h>
#include <string.h>

int width,height;
int map[101][101];

int main(void) {
	int tree_num;
	int tx,ty;
	int get_width,get_height;
	int i,j;
	int result,now;
	while(1) {
		scanf("%d",&tree_num);
		if(tree_num==0)break;
		scanf("%d%d",&width,&height);
		memset(map,0,sizeof(map));
		for(i=0;i<tree_num;i++) {
			scanf("%d%d",&tx,&ty);
			map[ty][tx]=1;
		}
		scanf("%d%d",&get_width,&get_height);
		for(i=1;i<=height;i++) {
			for(j=1;j<=width;j++) {
				map[i][j]+=map[i][j-1];
			}
		}
		for(i=1;i<=width;i++) {
			for(j=1;j<=height;j++) {
				map[j][i]+=map[j-1][i];
			}
		}
		result=0;
		for(i=get_height;i<=height;i++) {
			for(j=get_width;j<=width;j++) {
				now=map[i][j]
					-map[i-get_height][j]-map[i][j-get_width]
					+map[i-get_height][j-get_width];
				if(now>result)result=now;
			}
		}
		printf("%d\n",result);
	}
	return 0;
}