The distance between the segments
Easy
Execution time limit is 1 second
Runtime memory usage limit is 256 megabytes
Given two segments in space (x_1; y_1; z_1) - (x_2; y_2; z_2) and (x_3; y_3; z_3) - (x_4; y_4; z_4). Find the distance between the segments.
Input
Given integers x_1; y_1; z_1; x_2; y_2; z_2; x_3; y_3; z_3; x_4; y_4; z_4. The coordinates do not exceed 1000.
Output
Print the distance between the segments with at least 6 digits after the decimal point.
Examples
Input #1
Answer #1
Submissions 2K
Acceptance rate 14%