In a two-dimensional plane there are two line belts, there are two segments AB and CD, lxhgww's speed on AB is P and on CD is Q, he can move with the speed R on other area on the plane.
How long must he take to travel from A to D?
在二维平面中有两条线段AB和CD,lxhgww的速度在AB上是P,在CD上是Q,他可以在平面上的其他区域以速度R移动。
从A到D旅行最少需要多长时间?
其中一种情况的示意图如下
The first line is the case number T.
For each case, there are three lines.
The first line, four integers, the coordinates of A and B: Ax Ay Bx By.
The second line , four integers, the coordinates of C and D:Cx Cy Dx Dy.
The third line, three integers, P Q R.
0<= Ax,Ay,Bx,By,Cx,Cy,Dx,Dy<=1000
1<=P,Q,R<=10
第一行是案例编号T.
对于每种情况,有三行。
第一行,四个整数,A和B的坐标:Ax Ay Bx By。
第二行,四个整数,C和D的坐标:Cx Cy Dx Dy。
第三行,三个整数,P Q R
0 <= Ax,Ay,Bx,By,Cx,Cy,Dx,Dy <= 1000
1 <= P,Q,R <= 10
The minimum time to travel from A to D, round to two decimals.
从A运动到D的最短时间,四舍五入到两位小数。(貌似若结果与标准答案误差在0.01以内,是可以AC的)
8 0 0 4 1 4 1 0 2 8 8 1 0 0 0 100 100 0 100 100 2 2 1 8 0 23 8 4 2 91 0 4 9 10 0 0 2 2 0 2 2 0 4 3 1 1 8 1000 10 0 689 10 1000 90 1 20 4 9 4 20 4 41 4 60 4 4 1 4 9 4 20 4 91 4 60 4 3 1 0 5 8 5 2 5 4 0 6 9 3
1.03 136.60 8.30 0.83 49.60 28.50 42.75 0.93