#include <iostream>
#include <cmath>
using namespace std;



int main()
{
    int n,ukupno = 0;
    int prosecan_p;
    float b1,b2,b3;
    cin >> n;
    int a[n];
    int p[n];
    for (int x=0;x<n;x++){
        cin >> a[x] >> p[x];
        b3 = p[x];
        prosecan_p = prosecan_p + b3;
    }
    prosecan_p = prosecan_p / n;
    b3 = p[0];
    for (int x=0;x<n;x++){
        b2 = p[x];
        if (b2 > prosecan_p && b2 < b3) b3 = b2;
    }
    for (int x=0;x<n;x++){
        b1 = a[x];
        b2 = p[x];
        if(b2 > prosecan_p) ukupno = ukupno + (b1*(b3/100));
    }
    cout << ukupno;
}