#include <bits/stdc++.h>
using namespace std;
double dis[105], f[105][105];
int main() {
  int n, k, eps;
  scanf("%d%d%d", &n, &k, &eps);
  int x0, y0;
  scanf("%d%d", &x0, &y0);
  double maxd = 0;
  for (int i = 1; i <= n; i++) {
    int x, y;
    scanf("%d%d", &x, &y);
    dis[i] = sqrt((x - x0) * (x - x0) + (y - y0) * (y - y0));
    maxd = max(maxd, dis[i]);
  }
  double l, r;
  for (l = 0, r = maxd; r - l > 1e-8;) {
    double R = (l + r) / 2;
    memset(f, 0, sizeof(f));
    f[0][0] = 1;
    for (int i = 1; i <= n; i++)
      for (int j = 0; j < i; j++) {
        double p = dis[i] <= R ? 1 : exp(1 - dis[i] * dis[i] / R / R);
        f[i][j + 1] += f[i - 1][j] * p;
        f[i][j] += f[i - 1][j] * (1 - p);
      }
    double s = 0;
    for (int i = k; i <= n; i++) s += f[n][i];
    if (s * 1000 >= 1000 - eps)
      r = R;
    else
      l = R;
  }
  printf("%.7lf", l);
  return 0;
}
