#include <iostream>
#include <vector>
#include <utility>
#include <algorithm>
#include <iomanip>

using namespace std;

int main()
{
    int n;
    cin >> n;

    vector<pair<double, double>> procenatIZarada(n, make_pair(-1, -1));
    double suma1(0);
    for (int i = 0; i < n; ++i)
    {
        double x, y;
        cin >> x >> y;
        suma1 += x;
        procenatIZarada[i].first = y;
        procenatIZarada[i].second = x;
    }

    sort(procenatIZarada.begin(), procenatIZarada.end());

    double suma2(0);
    for (int i = 0; i < n; ++i)
    {
        if (suma2 < suma1*procenatIZarada[i].first/100) suma2 = suma1*procenatIZarada[i].first/100;
        suma1 -= procenatIZarada[i].second;
    }

    cout << fixed << setprecision(3) << suma2;

    return 0;
}