The distance between the segments
Easy
Execution time limit is 1 second
Runtime memory usage limit is 64 megabytes
Find distance between two segments.
Input
Eight of integers - the coordinates of the four ends of two segments. All input data are integers not exceeding modulo 10000.
Output
One number - the distance between the segments with an accuracy of less than 10^{-6}.
Examples
Input #1
Answer #1
Submissions 1K
Acceptance rate 19%