#include <bits/stdc++.h>
using namespace std;
int main() {
  std::cout << std::fixed;
  std::cout << std::setprecision(5);
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  double N, P;
  cin >> N >> P;
  double totalDrain = 0;
  priority_queue<pair<double, double>, vector<pair<double, double>>,
                 greater<pair<double, double>>>
      pq;
  for (double i = 0; i < N; i++) {
    double drainage, storage;
    cin >> drainage >> storage;
    totalDrain += drainage;
    pq.emplace(storage / drainage, drainage);
  }
  if (totalDrain <= P) {
    cout << "-1";
    return 0;
  }
  double currentTime = 0;
  double combinedDrainage = 0;
  double powerLeft = pq.top().first * pq.top().second;
  if (pq.size() == 1) {
    cout << (double)(pq.top().first * pq.top().second) / (pq.top().second - P);
    return 0;
  }
  for (double i = 0; i < N; i++) {
    pair<double, double> current = pq.top();
    pq.pop();
    combinedDrainage += current.second;
    double timeDiff = pq.top().first - currentTime;
    if ((combinedDrainage - P) * timeDiff > powerLeft) {
      currentTime += (powerLeft) / (combinedDrainage - P);
      cout << currentTime << endl;
      return 0;
    } else {
      powerLeft += (P - combinedDrainage) * timeDiff;
      currentTime = pq.top().first;
    }
  }
  currentTime += (powerLeft) / (combinedDrainage - P);
  cout << currentTime << endl;
  return 0;
}
