#include <bits/stdc++.h>
using namespace std;
struct point {
  int x, y;
};
double dist(const point& A, const point& B) {
  int dx = A.x - B.x;
  int dy = A.y - B.y;
  double dist2 = dx * dx + dy * dy;
  return sqrt(dist2);
}
struct polynomial {
  vector<double> C;
  polynomial() : C(vector<double>()) {}
  polynomial(double c0, double c1) : C(vector<double>(2)) {
    C[0] = c0;
    C[1] = c1;
  }
  int deg(void) const { return (int)C.size() - 1; }
};
polynomial operator*(const polynomial& A, const polynomial& B) {
  polynomial R = polynomial();
  int A_deg = A.deg(), B_deg = B.deg();
  int new_deg = A_deg + B_deg;
  R.C = vector<double>(new_deg + 1, 0.0);
  for (int i = 0; i <= A_deg; i++) {
    for (int j = 0; j <= B_deg; j++) {
      R.C[i + j] += A.C[i] * B.C[j];
    }
  }
  return R;
}
const int MAXN = 109;
int N, K;
double d[MAXN];
double eps;
double P(double D, double R) {
  if (D <= R)
    return 1.0;
  else {
    double div = D / R;
    return exp(1 - div * div);
  }
}
double prob(double r) {
  double prob_0 = P(d[0], r);
  polynomial R = polynomial(1 - prob_0, prob_0);
  for (int i = 1; i < N; i++) {
    double prob_i = P(d[i], r);
    R = R * polynomial(1 - prob_i, prob_i);
  }
  double res = 0.0;
  double R_deg = R.deg();
  for (int i = K; i <= R_deg; i++) res += R.C[i];
  return res;
}
double get_mx(void) {
  double res = 0.0;
  for (int i = 0; i < N; i++) res = max(res, d[i]);
  return res;
}
double solve(void) {
  double L = 0.0, R = get_mx(), M;
  for (int iteration = 0; iteration < 50; iteration++) {
    M = (L + R) * 0.5;
    if (prob(M) >= 1.0 - eps)
      R = M;
    else
      L = M;
  }
  return R;
}
int main() {
  cin >> N;
  cin >> K >> eps;
  eps /= 1000.0;
  point O;
  cin >> O.x >> O.y;
  for (int i = 0; i < N; i++) {
    point P;
    cin >> P.x >> P.y;
    d[i] = dist(O, P);
  }
  cout << setprecision(8);
  cout << solve();
  return 0;
}
