0092. Convex Hull
Имя входного файла: | conhull.in |
Имя выходного файла: | conhull.out |
Ограничение по времени: | 2 s |
Ограничение по памяти: | 64 megabytes |
Your task is to find the surface area and the volume of the convex hull of given N spheres of radius R.
Input file
First line contains two integer numbers 1 ≤ N ≤ 50 and 1 ≤ R ≤ 239. The next N lines are filled with coordinates of points in format xi yi zi. Coordinates are real numbers that do not exceed 1000 by an absolute value.
Output file
Output two real numbers with six digits after decimal point – the surface area and the volume.
Examples:
conhull.in | conhull.out |
---|---|
8 1 0 0 0 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 1 1 0 1 1 1 | 37.415927 20.613568 |
Источник: Petrozavodsk Winter 2003. Final Contest, Saturday, February 08
Обсудить Отправить решение
Версия для печати