#include <cstdio>
int input()
{
char cha;
int x=0,flag=1;
while(cha=getchar())
if(cha!=' '&&cha!='\n')
break;
if(cha=='-')
flag=-1;
else
x=cha-48;
while(cha=getchar())
{
if(cha==' '||cha=='\n')
break;
x=x*10+cha-48;
}
return flag*x;
}
int main()
{
int n,t,px,py;
while(1)
{
n=input();
t=input();
px=input();
py=input();
if(n==0&&t==0&&px==0&&py==0)
break;
int x,y,vx,vy,hit=0,x1,y1,x2,y2;
for(;n>0;n--)
{
x=input();y=input();vx=input();vy=input();
if(hit)
continue;
vx=x+vx*t;vy=y+vy*t;
x=x-px;y=y-py;//人到子彈起點的向量
vx=vx-px;vy=vy-py;//人到子彈終點的向量
if(x*vy-y*vx==0&&x*vx+y*vy<=0)//若外積=0(表示夾角=0或180)而且內積<=0(表示夾角大於90)則px和py會介在子彈起點到終點的路上
hit=1;
}
if(hit)
printf("true\n");
else
printf("false\n");
}
}