#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9 + 7;
const int N = 1e2 + 4;
long double eps;
int n;
int k, eps_in_mils;
int ox, oy;
int x[N], y[N];
long double f(long double xx, long double yy) {
  long double pwr = (long double)1.0 - (xx / yy) * (xx / yy);
  long double e = 2.7182818284590452353602874713527;
  return powl(e, pwr);
}
bool check(long double mid) {
  int cnt = 0;
  vector<long double> v;
  for (int i = 0; i < n; i++) {
    long double dis_here =
        fabs(ox - x[i]) * fabs(ox - x[i]) + fabs(oy - y[i]) * fabs(oy - y[i]);
    dis_here = sqrtl(dis_here);
    if (dis_here > mid) {
      v.push_back(f(dis_here, mid));
    } else
      cnt++;
  }
  if (cnt >= k) return 1;
  int req = k - cnt;
  long double dp[N][N];
  for (int i = 0; i < N; i++)
    for (int j = 0; j < N; j++) dp[i][j] = 0.0;
  int sz = (int)v.size();
  dp[0][0] = 1.0;
  for (int i = 0; i < sz; i++) {
    for (int j = 0; j <= i; j++) {
      dp[i + 1][j] += (1.0 - v[i]) * dp[i][j];
      dp[i + 1][j + 1] += v[i] * dp[i][j];
    }
  }
  double prob_here = 0.0;
  for (int i = req; i < sz + 1; i++) prob_here += dp[sz][i];
  return prob_here >= eps;
}
int main() {
  scanf("%d", &n);
  scanf("%d", &k);
  scanf("%d", &eps_in_mils);
  eps_in_mils = 1000 - eps_in_mils;
  scanf("%d", &ox);
  scanf("%d", &oy);
  eps = (long double)eps_in_mils / 1000.0;
  for (int i = 0; i < n; i++) scanf("%d", &x[i]), scanf("%d", &y[i]);
  long double low = 0.0, high = 4000000.0, ans;
  int iterations = 200;
  while (iterations--) {
    long double mid = (low + high) / 2.0;
    if (check(mid))
      ans = mid, high = mid;
    else
      low = mid;
  }
  cout << fixed << setprecision(10) << ans;
  return 0;
}
