| CAMA 2024 |
|---|
| Закончено |
We are playing "Twister" with Echomel, but he is a dirty cheater, and we believe not all his limbs are inside the game panel.
You are given two pairs of integers representing the coordinates of the bottom-left and top-right corners of the Twister panel, respectively. The game panel is a rectangle.
Next, you will be given 4 pairs of integers, representing the coordinates where Echomel has placed his left hand, right hand, left foot, and right foot, respectively.
Note 1: Echomel is VERY flexible.
The first line contains an integer $$$t$$$, $$$(1 \le t \le 1000)$$$.
The first line for each case contains the coordinates of the rectangle $$$x1, y1, x2, y2$$$, $$$(-10^9 \le x1, y1, x2, y2 \le 10^9)$$$, $$$(x1 \lt x2)$$$ y $$$(y1 \lt y2)$$$.
The first line for each case contains the coordinates of Echomel's hands and feet $$$mi_x, mi_y, md_x, md_y$$$, $$$pi_x, pi_y, pd_x, pd_y$$$, $$$(-10^9 \le mi_x, mi_y, md_x, md_y$$$, $$$pi_x, pi_y, pd_x, pd_y \le 10^9)$$$ — The coordinates of each hand and foot.
$$$m = hand$$$, $$$p = foot$$$, $$$i = left$$$, $$$d = right$$$.
Print YES if Echomel is playing legitimately; otherwise, he will need to be punished, so print NO if Echomel is being a bad boy, both responses without quotes.
21 1 5 51 5 5 5 1 1 1 52 2 3 42 2 3 4 4 4 0 1
YES NO
| Название |
|---|


