#include<algorithm>
#include<math.h>
#include<stdio.h>
using namespace std;
const double EPS = 1e-10;
const double INF = 1e+10;
const double PI = acos(-1);
int sig(double r) { return (r < -EPS) ? -1 : (r > +EPS) ? +1 : 0; }
inline double ABS(double a){return max(a,-a);}
struct Pt {
	double x, y;
	Pt() {}
	Pt(double x, double y) : x(x), y(y) {}
	Pt operator+(const Pt &a) const { return Pt(x + a.x, y + a.y); }
	Pt operator-(const Pt &a) const { return Pt(x - a.x, y - a.y); }
	Pt operator*(const Pt &a) const { return Pt(x * a.x - y * a.y, x * a.y + y * a.x); }
	Pt operator-() const { return Pt(-x, -y); }
	Pt operator*(const double &k) const { return Pt(x * k, y * k); }
	Pt operator/(const double &k) const { return Pt(x / k, y / k); }
	double ABS() const { return sqrt(x * x + y * y); }
	double abs2() const { return x * x + y * y; }
	double arg() const { return atan2(y, x); }
	double dot(const Pt &a) const { return x * a.x + y * a.y; }
	double det(const Pt &a) const { return x * a.y - y * a.x; }
};
double tri(const Pt &a, const Pt &b, const Pt &c) { return (b - a).det(c - a); }
int iSP(Pt a, Pt b, Pt c) {
	int s = sig((b - a).det(c - a));
	if (s) return s;
	if (sig((b - a).dot(c - a)) < 0) return -2; // c-a-b
	if (sig((a - b).dot(c - b)) < 0) return +2; // a-b-c
	return 0;
}

bool iSS(Pt a, Pt b, Pt c, Pt d) {
	return (iSP(a, b, c) * iSP(a, b, d) <= 0 && iSP(c, d, a) * iSP(c, d, b) <= 0);
}
Pt pLL(Pt a, Pt b, Pt c, Pt d) {
	b = b - a; d = d - c; return a + b * (c - a).det(d) / b.det(d);
}
double dSP(Pt a, Pt b, Pt c) {
	if (sig((b - a).dot(c - a)) <= 0) return (c - a).ABS();
	if (sig((a - b).dot(c - b)) <= 0) return (c - b).ABS();
	return ABS(tri(a, b, c)) / (b - a).ABS();
}
pair<Pt,Pt> pCL(Pt a, double r, Pt b, Pt c) {
	Pt h = b + (c - b) * (c - b).dot(a - b) / (c - b).abs2(); // perp(b, c, a)
	double d = (h - a).ABS();
	double y = sqrt(max(r * r - d * d, 0.0));
	Pt e = (c - b) / (c - b).ABS();
	return make_pair(h - e * y, h + e * y);
}
double x[12];
double y[12];
Pt p[12];
int main(){
	int a;
	while(scanf("%d",&a),a){
		double w,h,r,vx,vy;
		scanf("%lf%lf%lf%lf%lf",&w,&h,&r,&vx,&vy);
		for(int i=0;i<a;i++)scanf("%lf%lf",x+i,y+i);
		for(int i=0;i<a;i++)p[i]=Pt(x[i],y[i]);
		double t=0;
		Pt at=p[0];
		bool yet=true;
		int lt=-1;
		while(1){
			//at=at+Pt(vx,vy)*0.00001;
			Pt to=at+Pt(vx,vy)*10000;
			int ty=0;
			if((lt||sig(dSP(Pt(r,r),Pt(w-r,r),at)))&&iSS(at,to,Pt(r,r),Pt(w-r,r)))to=pLL(at,to,Pt(r,r),Pt(w-r,r));
			if((lt||sig(dSP(Pt(r,h-r),Pt(w-r,h-r),at)))&&iSS(at,to,Pt(r,h-r),Pt(w-r,h-r)))to=pLL(at,to,Pt(r,h-r),Pt(w-r,h-r));
			if((!lt||sig(dSP(Pt(r,r),Pt(r,h-r),at)))&&iSS(at,to,Pt(r,r),Pt(r,h-r))){to=pLL(at,to,Pt(r,r),Pt(r,h-r));ty=1;}
			if((!lt||sig(dSP(Pt(w-r,r),Pt(w-r,h-r),at)))&&iSS(at,to,Pt(w-r,r),Pt(w-r,h-r))){to=pLL(at,to,Pt(w-r,r),Pt(w-r,h-r));ty=1;}
			double L=(to-at).ABS();
			if(t+L>10000){
				to=at+(to-at)*(10000.0-t)/(L);
				
			}
			lt=ty;
			int v=-1;
			Pt tmp=to;
			double val=999999999;
			for(int i=1;i<a;i++){
				if(dSP(at,tmp,p[i])<r*2){
					pair<Pt,Pt> t2=pCL(p[i],r*2,at,tmp);
					if((t2.second-at).ABS()<(t2.first-at).ABS())tmp=t2.second;
					else tmp=t2.first;
		//			printf("%f %d\n",dSP(at,to,p[i]),i);
					val=(p[i]-at).ABS();
					v=i;
				}
			}
			if(~v){
			//	printf("%f %f\n",to.x,to.y);
				printf("%d\n",v+1);
				yet=false;break;
			}
			at=to;
			t+=L;
			if(t>10000-EPS)break;
			if(ty)vx=-vx;
			else vy=-vy;
		//	printf("%f %f %f\n",at.x,at.y,t);
		}
		if(yet)printf("-1\n");
	}
}

Measured memory_bytes: 1080