#include using namespace std; using ll=long long; using P=pair; int main(){ ll n,k; cin>>n>>k; vector x(n+2),y(n+2); for(ll i=0;i<=n+1;i++){ cin>>x[i]>>y[i]; } ll ok=1e18,ng=0; while(abs(ok-ng)>1){ ll mid=(ok+ng)/2; vector dist(n+2,1e18); dist[0]=0; priority_queue,greater

> que; que.push(P(dist[0],0)); while(que.size()){ P q=que.top(); que.pop(); ll d=q.first; ll from=q.second; if(dist[from]next){ dist[to]=next; que.push(P(dist[to],to)); } } } if(dist[1]<=k){ ok=mid; }else{ ng=mid; } } cout<