Problem: Takahashi wants to grill N pieces of meat on a grilling net, which can be seen as a two-dimensional plane. The coordinates of the i-th piece of meat are \left(x_i, y_i\right), and its hardness is c_i.

Takahashi can use one heat source to grill the meat. If he puts the heat source at coordinates \left(X, Y\right), where X and Y are real numbers, the i-th piece of meat will be ready to eat in c_i \times \sqrt{\left(X - x_i\right)^2 + \left(Y-y_i\right)^2} seconds.

Takahashi wants to eat K pieces of meat. Find the time required to have K or more pieces of meat ready if he put the heat source to minimize this time.

Constraints

* All values in input are integers.
* 1 \leq N \leq 60
* 1 \leq K \leq N
* -1000 \leq x_i , y_i \leq 1000
* \left(x_i, y_i\right) \neq \left(x_j, y_j\right) \left(i \neq j \right)
* 1 \leq c_i \leq 100

Input

Input is given from Standard Input in the following format:


N K
x_1 y_1 c_1
\vdots
x_N y_N c_N


Output

Print the answer.

It will be considered correct if its absolute or relative error from our answer is at most 10^{-6}.

Examples

Input

4 3
-1 0 3
0 0 3
1 0 2
1 1 40


Output

2.4


Input

10 5
-879 981 26
890 -406 81
512 859 97
362 -955 25
128 553 17
-885 763 2
449 310 57
-656 -204 11
-270 76 40
184 170 16


Output

7411.2252

Solution (in CPP):

Solution:
#include <bits/stdc++.h>

#define FOR(i,a,b) for (int i=(a);i<(b);++i)
#define REP(i,n) for (int i=0;i<(n);++i)

using namespace std;

vector<pair<double, double>> circle_intersections(double cx1, double cy1, double r1, double cx2, double cy2, double r2) {
    double dx = cx2 - cx1;
    double dy = cy2 - cy1;
    double dx_2 = dx * dx;
    double dy_2 = dy * dy;
    double d_2 = dx_2 + dy_2;
    double d = sqrt(d_2);
    if (d > r1 + r2 || d < abs(r1 - r2)) {
        return { };
    }
    double r1_2 = r1 * r1;
    double r2_2 = r2 * r2;
    double D = r1_2 * r2_2 - pow(r1_2 + r2_2 - d_2, 2) / 4;
    if (D < 0) {
        return { };
    }
    double C = (r1_2 - r2_2) / d_2;
    double Ax = ((cx1 + cx2) + dx * C) / 2;
    double Ay = ((cy1 + cy2) + dy * C) / 2;
    double E = sqrt(D) / d_2;
    double Bx = dy * E;
    double By = dx * E;
    double x1 = Ax + Bx;
    double x2 = Ax - Bx;
    double y1 = Ay - By;
    double y2 = Ay + By;
    return { make_pair(x1, y1), make_pair(x2, y2) };
}

int main() {
    cin.tie(0);
    ios::sync_with_stdio(false);

    constexpr int C_MAX = 100;
    constexpr int ABS_X_MAX = 1000;

    int N, K;
    cin >> N >> K;
    vector<int> x(N), y(N), c(N);
    REP(i, N) {
        cin >> x[i] >> y[i] >> c[i];
    }

    double low = 0;
    double high = C_MAX * (ABS_X_MAX * 2);
    while (high - low > 1e-10) {
        double t = (low + high) / 2;
        vector<pair<double, double>> points;
        REP(i, N) {
            points.emplace_back(x[i], y[i]);
        }
        REP(i, N) FOR(j, i + 1, N) {
            double ri = t / c[i];
            double rj = t / c[j];
            auto intersections = circle_intersections(x[i], y[i], ri, x[j], y[j], rj);
            for (auto &[a, b] : intersections) {
                points.emplace_back(a, b);
            }
        }
        bool is_enough_time = false;
        for (auto &[a, b] : points) {
            int n_in = 0;
            REP(i, N) {
                double r = t / c[i];
                if (pow(x[i] - a, 2) + pow(y[i] - b, 2) <= r * r + 1e-9) {
                    ++n_in;
                }
            }
            if (n_in >= K) {
                is_enough_time = true;
                break;
            }
        }
        if (is_enough_time) {
            high = t;
        } else {
            low = t;
        }
    }
    double t = (low + high) / 2;

    cout << setprecision(20) << fixed << t << endl;

    return 0;
}