#include <bits/stdc++.h>
using namespace std;
int N, K;
int eps;
int D2[105];
double R[105][105];
bool check(double Rp) {
  double P[105];
  if (Rp < 1e-7) {
    for (int i = 0; i < (N); i++)
      if (D2[i] == 0)
        P[i] = 1;
      else
        P[i] = 0;
  } else {
    for (int i = 0; i < (N); i++)
      if (D2[i] < Rp * Rp)
        P[i] = 1;
      else
        P[i] = exp(1 - D2[i] / Rp / Rp);
  }
  for (int i = 0; i < (N + 1); i++) R[0][i] = 0;
  R[0][0] = 1 - P[0];
  R[0][1] = P[0];
  for (int i = 1; i < N; i++) {
    R[i][0] = R[i - 1][0] * (1 - P[i]);
    for (int j = 1; j <= N; j++)
      R[i][j] = R[i - 1][j] * (1 - P[i]) + R[i - 1][j - 1] * P[i];
  }
  double res = 0.0;
  for (int i = K; i <= N; i++) res += R[N - 1][i];
  return res >= 1 - eps * 0.001;
}
int main() {
  scanf("%d%d%d", &N, &K, &eps);
  int X0, Y0;
  scanf("%d%d", &X0, &Y0);
  for (int i = 0; i < (N); i++) {
    int X, Y;
    scanf("%d%d", &X, &Y);
    D2[i] = (X - X0) * (X - X0) + (Y - Y0) * (Y - Y0);
  }
  double a = 0;
  double b = 1e12;
  while (a + 1e-8 < b) {
    double s = (a + b) / 2;
    if (check(s))
      b = s;
    else
      a = s;
  }
  printf("%.9lf\n", a);
}
