EQBOX - Equipment Box


There is a large room in the Pyramid called Room-of-No-Return. Its floor is covered by rectangular tiles of equal size. The name of the room was chosen because of the very high number of traps and mechanisms in it. The ACM group has spent several years studying the secret plan of this room. It has made a clever plan to avoid all the traps. A specially trained mechanic was sent to deactivate the most feared trap called Shattered Bones. After deactivating the trap the mechanic had to escape from the room. It is very important to step on the center of the tiles only; he must not touch the edges. One wrong step and a large rock falls from the ceiling squashing the mechanic like a pancake. After deactivating the trap, he realized a horrible thing: the ACM plan did not take his equipment box into consideration. The box must be laid onto the ground because the mechanic must have both hands free to prevent contact with other traps. But when the box is laid on the ground, it could touch the line separating the tiles. And this is the main problem you are to solve.

Input

The input consists of T test cases (T is equal to about 10000). The number of them (T) is given on the first line of the input file. Each test case consists of a single line. The line contains exactly four integer numbers separated by spaces: A, B, X and Y. A and Bindicate the dimensions of the tiles, X and Y are the dimensions of the equipment box (1 <= A,B,X,Y <= 50000).

Output

Your task is to determine whether it is possible to put the box on a single tile -- that is, if the whole box fits on a single tile without touching its border. If so, you are to print one line with the sentence "Escape is possible.". Otherwise print the sentence "Box cannot be dropped.".

Example

Sample Input:

2
10 10 8 8
8 8 10 10

Sample output:

Escape is possible.
Box cannot be dropped.
Warning: large Input/Output data, be careful with certain languages

hide comments
BMacZero: 2014-06-13 00:43:29

My AC solution returns "Escape is possible." on "10 10 10 10". It's possible that the test cases simply avoid checking cases like that.

Pranshul Agarwal: 2012-06-13 15:24:06

The problem is more complicated than it appears at first sight... the box can make some angle with the sides of the tile...

Last edit: 2012-06-13 15:24:46
Rocker3011: 2012-06-06 20:56:32

i tried to do this problem a long while ago, now i see it, i realize what it really is...still can`t do it :D

:D: 2012-05-25 12:33:31

That's a C++ style casting (primitive constructor in a way). In C you must do x = (int)x. This is not an issue with SPOJ. If you want to test more see ideone.com

nilesh soni: 2012-05-25 12:22:58

in every spoj problem for int part of float x=int(x) does not accepted, it shows error that there must be expression before int ....
why i m getting this error...???

Surya kiran: 2013-07-31 22:05:48

@vishranth goyal think of this test case
9 9 10 1
the box can be rotated and can be made fit inside tile

strings: 2012-04-22 21:55:06

i don't get why my solution is wrong...
i made a simple logic that larger dimension of tile should be larger than larger dimension of box and similarly the other one...
pls tell what's wrong
@adrian kosowski

Kevin Zheng: 2011-07-04 02:43:31

Would a box with dimensions 10x10 'fit' inside a 10x10 tile?

Santiago Palacio: 2011-05-09 08:43:25

how is this case?:
1
1 1 1 1

is it supposed to fit or not?
thanks.

Last edit: 2011-05-10 03:47:13
Alex Anderson: 2011-03-19 02:29:58

Large I/O means that there is a large amount of input to read in, output to print out.


Added by:adrian
Date:2004-06-06
Time limit:5s
Source limit:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Languages:All
Resource:ACM Central European Programming Contest, Prague 1999