#include <bits/stdc++.h>
#include <experimental/random>
#include <random>
//#include <ext/pb_ds/assoc_container.hpp>
//using namespace __gnu_pbds;
using namespace std;
using ld = long double;
using ll = long long;
const ll INF = 2e9, MOD = 1e9 + 7;
void solve();
signed main() {
#ifdef LOCAL
freopen("input.txt", "r", stdin);
freopen("output.txt", "w", stdout);
#endif
ios::sync_with_stdio(false);
cin.tie(0);
int q = 1;
//cin >> q;
while (q--) {
solve();
}
}
vector<pair<ll, ll>> a;
ll n, k;
ld get(ll x) {
vector<vector<ld>> dp(x + 1, vector<ld>(k - x + 1, INF));
dp[0][0] = 0;
ll col = 1;
for (auto [sec, fir] : a) {
vector<vector<ld>> ndp(x + 1, vector<ld>(k - x + 1, INF));
for (int i = 0; i <= min(x, col); i++) {
for (int j = 0; j <= min(col - i, k - x); j++) {
ndp[i][j] = dp[i][j];
if (i != 0) {
ndp[i][j] = min(ndp[i][j], dp[i - 1][j] + (ld) sec / (ld) i);
}
if (j != 0) {
ndp[i][j] = min(ndp[i][j], dp[i][j - 1] + (ld) fir / (ld) (x + 1));
}
}
}
dp = ndp;
col++;
}
return dp[x][k - x];
}
void solve() {
cin >> n >> k;
for (int i = 0; i < n; i++) {
ll x, y; cin >> x >> y;
if (y == -1) y = INF;
a.emplace_back(y, x);
}
sort(a.begin(), a.end());
ld ans = INF;
for (int x = 0; x <= k; x++) {
ans = min(ans, get(x));
}
cout << fixed << setprecision(9) << ans;
}