#include typedef long long ll; typedef long double ld; using namespace std; vector> broom; ld sq_dist(pair x, pair y) { return (x.first-y.first)*(x.first-y.first) + (x.second-y.second)*(x.second-y.second); } ld scalar(pair x, pair y) { return x.first*y.first + x.second*y.second; } void add_boat(pair boat, pair v, ld SQ, ld b_len) { ld proj_len = scalar(boat,v); pair projection = make_pair(v.first * proj_len, v.second * proj_len); ld H = sq_dist(boat, projection); ld dif = SQ - H; if(dif < 0.0) return; ld rad = sqrt(dif); ld bg = proj_len - rad; ld ed = proj_len + rad; if(ed < 0.0) return; if(bg > b_len) return; broom.push_back(make_pair(bg,1)); broom.push_back(make_pair(ed,-1)); } int main() { ll n,r,A,B; scanf("%lld%lld%lld%lld",&n,&r,&A,&B); ld R = ld(r) + 2e-4; pair vec_ab = make_pair(ld(A),ld(B)); ld norm_ab = sqrt(scalar(vec_ab, vec_ab)); pair normal_ab = make_pair(ld(A)/norm_ab,ld(B)/norm_ab); ld b_len = sqrt(scalar(vec_ab,vec_ab)); for(int i=1;i<=n;i++) { ll x,y; scanf("%lld%lld",&x,&y); add_boat(make_pair(ld(x), ld(y)), normal_ab, R*R, b_len); } sort(broom.begin(), broom.end(), [](pair a, pair b){return a.first