#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9 + 7;
const long long inf = 3e18 + 5;
int add(int a, int b) { return (a += b) < mod ? a : a - mod; }
int mul(int a, int b) { return 1LL * a * b % mod; }
const long double eps = 1e-5;
const int maxn = 100005;
long long a[maxn], b[maxn], n, p;
bool f(long double x) {
  long double give = 0;
  for (int i = 0; i < n; i++) {
    long double all =
        max((long double)0, (long double)a[i] - (long double)b[i] / x);
    give += all;
  }
  return give <= p;
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cin >> n >> p;
  for (int i = 0; i < n; i++) cin >> a[i] >> b[i];
  if (accumulate(a, a + n, 0ll) <= p) return cout << -1, 0;
  long double lo = 0, hi = 1e18;
  while (abs(lo - hi) > eps) {
    long double mid = (lo + hi) / 2;
    if (f(mid))
      lo = mid;
    else
      hi = mid;
  }
  cout << fixed << setprecision(10) << lo;
}
