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

建议使用的浏览器:

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

2056:Rectangles

题目描述
Given two rectangles and the coordinates of two points on the diagonals of each rectangle,you have to calculate the area of the intersected part of two rectangles. its sides are parallel to OX and OY .
输入解释
Input The first line of input is 8 positive numbers which indicate the coordinates of four points that must be on each diagonal.The 8 numbers are x1,y1,x2,y2,x3,y3,x4,y4.That means the two points on the first rectangle are(x1,y1),(x2,y2);the other two points on the second rectangle are (x3,y3),(x4,y4).
输出解释
Output For each case output the area of their intersected part in a single line.accurate up to 2 decimal places.
输入样例
1.00 1.00 3.00 3.00 2.00 2.00 4.00 4.00
5.00 5.00 13.00 13.00 4.00 4.00 12.50 12.50
输出样例
1.00
56.25
来自杭电HDUOJ的附加信息
Author seeyou
Recommend linle

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

题目来源 校庆杯Warm Up

源链接: HDU-2056

最后修改于 2020-10-25T22:50:07+00:00 由爬虫自动更新

共提交 17

通过率 88.24%
时间上限 内存上限
1000/1000MS(Java/Others) 32768/32768K(Java/Others)