A rectangular board with sides parallel to the coordinate axes lies on a two-dimensional plane. The bottom-left corner of the region is at coordinate $$$(0, 0)$$$ while the top-right corner is at coordinate $$$(H, W)$$$.
Given three rectangular cards, you need to put these three cards fully inside the board to cover the whole board and find the number of different placements. Here the cards should not be rotated or flipped, the sides of each card should be parallel to the coordinate axes, and the corners of each card should have integral coordinates.
Two placements are considered different if and only if there exists a card with different locations in the two placements. Since the answer may be large, output it modulo $$$10^9 + 7$$$.
The input contains several test cases, and the first line contains a single integer $$$T$$$ ($$$1 \le T \le 10^5$$$), denoting the number of test cases.
For each test case:
The first line contains two integers $$$H$$$ and $$$W$$$ ($$$1 \le H, W \le 10^9$$$), denoting the height and the width of the rectangular board.
Then three lines follow, the $$$i$$$-th of which contains two integers $$$h_i$$$ ($$$1 \le h_i \le H$$$) and $$$w_i$$$ ($$$1 \le w_i \le W$$$), denoting the height and the width of the $$$i$$$-th rectangular card.
For each test case, output a line containing a single integer, indicating the number of different placements that satisfy the conditions, modulo $$$10^9 + 7$$$.
52 21 11 11 12 21 11 21 22 21 11 22 12 21 21 21 22 21 21 22 1
0 8 4 6 4
41 31 11 21 31 41 11 21 31 51 11 21 31 61 11 21 3
6 12 14 6
11000000000 10000000001 11 11000000000 1000000000
2401
| Name |
|---|


