#include <iostream>
#include <vector>
#include <cmath>
#include <iomanip>

using namespace std;

int main() {
    int n, k;
    cin >> n >> k;
    vector<int> pop(n), dist(n);
    for (int i = 0; i < n; ++i) {
        cin >> pop[i] >> dist[i];
    }

    vector<double> dp(n, 0);
    vector<double> place(n);
    for (int j = 1; j <= k; ++j) {
        vector<double> new_place(n, 0);
        vector<double> new_dp(n, 0);
        for (int i = 0; i < n; ++i) {       // place recurrence
            double utility = 0;
            for (int l = 0; l <= 30; ++l) {
                if (i-l < 0)
                    break;
                utility += pop[i-l]*pow(2.0, -(dist[i]-dist[i-l]));
                double new_ans = i-l-1 >= 0 ? (utility+dp[i-l-1]) : utility;
                new_place[i] = max(new_place[i], new_ans);
            }
        }
        for (int i = 0; i < n; ++i) {       // dp recurrence
            if (i > 0)
                new_dp[i] = new_dp[i-1];
            double utility = 0;
            for (int l = 0; l <= 30; ++l) {
                new_dp[i] = max(new_dp[i], new_place[i-l]+utility);
                if (i-l-1 < 0)
                    break;
                utility *= pow(2.0, -(dist[i-l]-dist[i-l-1]));
                utility += pop[i-l]*pow(2.0, -(dist[i-l]-dist[i-l-1]));
            }
        }
        dp = new_dp;
        place = new_place;
    }
    cout.precision(18);
    cout << dp[n-1] << endl;
}
