#include <bits/stdc++.h>
using namespace std;
template <typename T1, typename T2>
inline T1 max(T1 a, T2 b) {
  return a < b ? b : a;
}
template <typename T1, typename T2>
inline T1 min(T1 a, T2 b) {
  return a < b ? a : b;
}
const char lf = '\n';
namespace ae86 {
const int bufl = 1 << 15;
char buf[bufl], *s = buf, *t = buf;
inline int fetch() {
  if (s == t) {
    t = (s = buf) + fread(buf, 1, bufl, stdin);
    if (s == t) return EOF;
  }
  return *s++;
}
inline int ty() {
  int a = 0;
  int b = 1, c = fetch();
  while (!isdigit(c)) b ^= c == '-', c = fetch();
  while (isdigit(c)) a = a * 10 + c - 48, c = fetch();
  return b ? a : -a;
}
}  // namespace ae86
using ae86::ty;
const int _ = 50007, __ = _ << 1;
const long double eps = 1e-10, na = sqrt(-1.00);
inline int dcmp(long double x) {
  if (-eps < x && x < eps) return 0;
  return x > 0 ? 1 : -1;
}
struct points {
  long double x, y;
  points(long double x_ = 0, long double y_ = 0) { x = x_, y = y_; }
  friend points operator+(points a, points b) {
    return points(a.x + b.x, a.y + b.y);
  }
  friend points operator-(points a, points b) {
    return points(a.x - b.x, a.y - b.y);
  }
  friend points operator*(points a, long double b) {
    return points(a.x * b, a.y * b);
  }
  friend points operator/(points a, long double b) {
    return points(a.x / b, a.y / b);
  }
  int valid() { return !isinf(x) && !isnan(x) && !isinf(y) && !isnan(y); }
};
inline long double dox(points a, points b) { return a.x * b.x + a.y * b.y; }
inline long double cox(points a, points b) { return a.x * b.y - a.y * b.x; }
inline long double length2(points a) { return dox(a, a); }
inline long double distan(points a, points b) { return sqrt(length2(b - a)); }
inline long double angle(points a) { return atan2(a.y, a.x); }
struct lines {
  long double k, b;
  lines(long double k_ = 0, long double b_ = 0) { k = k_, b = b_; }
  long double f(long double x) { return k * x + b; }
};
points llcrash(lines a, lines b) {
  long double x = (b.b - a.b) / (a.k - b.k);
  return points(x, a.f(x));
}
struct circles {
  points x;
  long double r;
  circles(points x_ = points(), long double r_ = 0) { x = x_, r = r_; }
};
pair<points, points> clcrash(circles c, lines l) {
  long double k = l.k, b = l.b, p = c.x.x, q = c.x.y, r = c.r;
  long double A = 1 + k * k;
  long double B = -2 * p + 2 * k * b - 2 * q * k;
  long double C = b * b + p * p - 2 * q * b + q * q - r * r;
  if (B * B - 4 * A * C <= 0) return make_pair(points(na, na), points(na, na));
  long double dlt = sqrt(B * B - 4 * A * C);
  long double xx1 = (-B - dlt) / (A + A), yy1 = l.f(xx1);
  long double xx2 = (-B + dlt) / (A + A), yy2 = l.f(xx2);
  return make_pair(points(xx1, yy1), points(xx2, yy2));
}
struct tla {
  static const int _t = __;
  long long t[_t];
  void add(int x, long long d) {
    while (x < _t) t[x] += d, x += ((x) & (-(x)));
  }
  int sum(int x) {
    long long d = 0;
    while (x) d += t[x], x -= ((x) & (-(x)));
    return d;
  }
  void cls() { memset(t, 0, sizeof(t)); }
} t;
lines p[_];
long double pxl[_], pxr[_];
int n, tar, las[_];
points bas;
pair<long double, int> ps[__];
int lps = 0;
long long finder(long double r) {
  t.cls(), lps = 0;
  circles org(bas, r);
  for (int i = 1; i <= n; i++) {
    auto ret = clcrash(org, p[i]);
    if (!ret.first.valid() || !ret.second.valid()) continue;
    ps[++lps] = make_pair(angle(ret.first - bas), i);
    ps[++lps] = make_pair(angle(ret.second - bas), i);
    pxl[i] = min(ps[lps - 1].first, ps[lps].first);
    pxr[i] = max(ps[lps - 1].first, ps[lps].first);
  }
  sort(ps + 1, ps + lps + 1);
  memset(las, 0, sizeof(las));
  long long ans = 0;
  for (int i = 1; i <= lps; i++) {
    int x = ps[i].second;
    if (las[x])
      ans += t.sum(i) - t.sum(las[x]), t.add(las[x], -1);
    else
      las[x] = i, t.add(las[x], 1);
  }
  return ans;
}
int main() {
  ios::sync_with_stdio(0), cout.tie(nullptr);
  n = ty();
  bas.x = ty() / 1000.00, bas.y = ty() / 1000.00, tar = ty();
  for (int i = 1; i <= n; i++) p[i].k = ty() / 1000.00, p[i].b = ty() / 1000.00;
  long double l = 0, r = 1000000000000.00;
  int lim = 252;
  while (r > l && --lim > 0) {
    long double mid = (l + r) / 2;
    if (finder(mid) >= tar)
      r = mid;
    else
      l = mid;
  }
  finder(l);
  int cnt = 0;
  long double ans = 0;
  set<pair<long double, int>> s;
  memset(las, 0, sizeof(las));
  for (int i = 1; i <= lps; i++) {
    int x = ps[i].second;
    if (!las[x]) {
      auto it = s.lower_bound(make_pair(pxl[x], -1));
      while (it != s.end() && it->first < pxr[x])
        ans += distan(bas, llcrash(p[it->second], p[x])), cnt++, it++;
      las[x] = 1, s.emplace(pxr[x], x);
    } else
      s.erase(s.find(make_pair(pxr[x], x)));
  }
  ans += l * (tar - cnt);
  cout << setprecision(10) << fixed << ans << lf;
  return 0;
}
