#include<iostream> #include<stdio.h> #include<cmath> using namespace std; int main() { int n; double a,b,c,d,t; double x,y,z; scanf("%d",&n); while(n--) { scanf("%lf%lf%lf%lf",&a,&b,&c,&d); if(a>b){t=a; a=b; b=t;} if(c>d){t=c; c=d; d=t;} if(a>=c&&b>=d){cout<<"Escape is possible."<<endl;continue;} if(a<c||a*b<=c*d) {cout<<"Box cannot be dropped."<<endl;continue;} x=asin(a/sqrt(c*c+d*d)); y=atan(c/d); z=x-y; double e=cos(x)*sqrt(c*c+d*d); double f=2*c*sin(z); /* double r=sqrt(c*c+d*d); double p=sqrt(r*r-a*a); x=atan(a/p); y=atan(d/c); z=x+y; double f=-cos(z)*c; if(p+2*f<b) */ if(e+f<b) {cout<<"Escape is possible."<<endl;continue;} cout<<"Box cannot be dropped."<<endl; } return 0; } http://acm.pku.edu.cn/JudgeOnline/problem?id=1380