#include <bits/stdc++.h>
using namespace std;
const int maxN = 100 + 5;
const double EPS = 1e-10;
int n, k, epsi, Ox, Oy;
int x[maxN], y[maxN], dis[maxN];
double yes[maxN], no[maxN];
double dp[maxN][maxN];
inline int P2(int x) { return x * x; }
inline bool ok(double R) {
  double RR = R * R;
  for (int i = 1; i <= n; i++) {
    if (dis[i] < RR + EPS) {
      yes[i] = 1;
      no[i] = 0;
    } else {
      yes[i] = exp(1 - (double)dis[i] / RR);
      no[i] = 1 - yes[i];
    }
  }
  dp[0][0] = 1;
  for (int i = 1; i <= n; i++) {
    dp[i][0] = no[i] * dp[i - 1][0];
    for (int j = 1; j <= k; j++) {
      if (i < j)
        dp[i][j] = 0;
      else {
        dp[i][j] = yes[i] * dp[i - 1][j - 1];
        dp[i][j] += no[i] * dp[i - 1][j];
      }
    }
  }
  double ret = 0;
  for (int i = 0; i < k; i++) ret += dp[n][i];
  return ret + EPS < (double)epsi / 1000;
}
inline double bs() {
  double res = -1;
  double beg = 0, fin = 3000.0;
  for (int i = 1; i <= 100; i++) {
    double mid = (beg + fin) / 2;
    if (ok(mid)) {
      res = mid;
      fin = mid;
    } else
      beg = mid;
  }
  return res;
}
int main() {
  cin >> n >> k >> epsi;
  cin >> Ox >> Oy;
  for (int i = 1; i <= n; i++) {
    cin >> x[i] >> y[i];
    dis[i] = P2(x[i] - Ox) + P2(y[i] - Oy);
  }
  cout << fixed << setprecision(10) << bs() << endl;
  return 0;
}
