a,b;main(t){for(scanf("%*d%*d%d%d",&a,&b);~scanf("%d",&t);b=t>b^ba^a