当前你的浏览器版本过低,网站已在兼容模式下运行,兼容模式仅提供最小功能支持,网站样式可能显示不正常。
请尽快升级浏览器以体验网站在线编辑、在线运行等功能。

建议使用的浏览器:

谷歌Chrome 火狐Firefox Opera浏览器 微软Edge浏览器 QQ浏览器 360浏览器 傲游浏览器

5126:stars

题目描述
John loves to see the sky. A day has Q times. Each time John will find a new star in the sky, or he wants to know how many stars between $(x_1, y_1, z_1)$ and $(x_2, y_2, z_2)$.
输入解释
The first line contains a single integer $T(1 \leq T \leq 10)$ (the data for $Q > 100$ less than 6 cases),, indicating the number of test cases.
The first line contains an integer $Q(1 \leq Q \leq 50000)$,indicating how many times in a day.
Next Q lines contain some integers, first input an integer $A(1 \leq A \leq 2)$.If A=1 then input 3 integers x, y and z, indicating a coordinate of one star.. If A=2 then input 6 integers $x_1, y_1, z_1, x_2, y_2, z_2(1 \leq x, y, z, x_1, y_1, z_1, x_2, y_2, z_2 \leq 10^9, x_1 \leq x_2, y_1 \leq y_2, z_1 \leq z_2)$.
输出解释
For each “A=2”,output an integer means how many stars in such a section.
输入样例
2
11
1 1 1 1
2 1 1 1 1 1 1
1 2 2 2
1 1 1 2
2 1 1 1 2 2 2
1 3 3 3
1 4 4 4
1 5 5 5
1 6 6 6
2 1 1 1 6 6 6
2 3 3 3 6 6 6
11
1 1 1 1
2 1 1 1 1 1 1
1 2 2 2
1 1 1 2
2 1 1 1 2 2 2
1 3 3 3
1 4 4 4
1 5 5 5
1 6 6 6
2 1 1 1 6 6 6
2 3 3 3 6 6 6
输出样例
1
3
7
4
1
3
7
4
来自杭电HDUOJ的附加信息
Recommend heyang

该题目是Virtual Judge题目,来自 杭电HDUOJ

题目来源 BestCoder Round #20

源链接: HDU-5126

最后修改于 2020-10-25T23:20:01+00:00 由爬虫自动更新

共提交 0

通过率 --%
时间上限 内存上限
20000/10000MS(Java/Others) 32768/32768K(Java/Others)