Maneuvering
题号:NC15877
时间限制:C/C++/Rust/Pascal 1秒,其他语言2秒
空间限制:C/C++/Rust/Pascal 256 M,其他语言512 M
64bit IO Format: %lld

题目描述

It’s universally acknowledged that there’re innumerable trees in the campus of HUST.

A space ship commonly uses small engines for its attitude control and maneuvering. DK tells you the engine layout of a ship and the ship’s moment of inertia in local space. Assume the moment of inertia for x, y and z axis are all the same. Tell him the max counter-clockwise angular acceleration on +z axis while the ship has no translation on any axis, and has no rotation on x and y axis. Notice DK uses right-hand coordinate system.

输入描述:

The first line contains number n (1≤n≤100), the number of engines.
The second line contains a real number I, indicates the moment of inertia.
For the next n lines, each line contains seven real number F,x,y,z,a,b,c, indicates an engine which has a maximum thrust F(0≤F≤100) towards (a,b,c) is located at (x,y,z), where -100≤x,y,z,a,b,c≤100.
Every real number as input has 6 digits after point.
All data is randomly generated.

输出描述:

One line contains the max angular acceleration.
Round your answer to .
示例1

输入

复制
2
1.000000
3.000000 1.000000 0.000000 0.000000 0.000000 1.000000 0.000000
1.000000 -1.000000 0.000000 0.000000 0.000000 -1.000000 0.000000

输出

复制
2.0000