Fish Catch

No attempts yetTime limit1sMemory limit128 MB

Problem

Fishermen off the coast catch a very lazy kind of fish that swims along a straight line at a constant speed, almost never changing its direction or velocity. Each fisherman uses a circular net whose radius can be adjusted freely, and has already fixed the center of the net at a single point.

There are NN fish. For each fish you are given its position at time 00 and its position one second later; the fish keeps moving along the straight line through those two points at the same constant speed. The fishermen may lower the net at any single moment t0t \ge 0, and a fish is caught if at that moment it lies inside or on the boundary of the net.

They want to catch at least KK fish in one dip, but they do not want to catch more than necessary so that enough fish remain in the ocean, so they want the net as small as possible. Find the smallest radius RR such that there exists a moment t0t \ge 0 at which at least KK fish lie within distance RR of the center.

Input

The first line contains two integers CxC_x and CyC_y (1Cx,Cy1041 \le C_x, C_y \le 10^4), the coordinates of the center of the net.

The second line contains two integers NN and KK (5N10005 \le N \le 1000, 1KN1 \le K \le N).

Each of the next NN lines contains four integers AxA_x, AyA_y, BxB_x, ByB_y (0Ax,Ay,Bx,By1040 \le A_x, A_y, B_x, B_y \le 10^4): (Ax,Ay)(A_x, A_y) is the position of a fish at time 00, and (Bx,By)(B_x, B_y) is its position at time 11. Each fish moves along a straight line at constant speed, so at time tt it is located at (Ax+t(BxAx), Ay+t(ByAy))(A_x + t (B_x - A_x),\ A_y + t (B_y - A_y)).

Output

Print a single real number RR, the required radius of the net, rounded to exactly 55 digits after the decimal point, followed by a newline.