using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace _B_Frilenseri
{
    class Program
    {
        public class Frilenser
        {
            public double Zarada;
            public double Procenat;
        }

        static void Main(string[] args)
        {
            List<Frilenser> frilensers = new List<Frilenser>();
            int n;

            n = int.Parse(Console.ReadLine());

            for(int i = 0; i<n; i++)
            {               
                var ulaz = Console.ReadLine().Split();
                var frilenser = new Frilenser();
                frilenser.Zarada = double.Parse(ulaz[0]);
                frilenser.Procenat = double.Parse(ulaz[1]);
                frilensers.Add(frilenser);
            }

            //Math.Round(3.5m, MidpointRounding. )
            double ukupanPorez = 0;
            frilensers = frilensers.OrderByDescending(x => x.Procenat).ToList();
            foreach(var frilenser in frilensers)
            {
                var procenat = frilenser.Procenat;
                var porez = frilensers.Where(x => x.Procenat >= procenat).Sum(x => x.Zarada) * procenat / 100;
                //porez = Math.Round(porez, )
                //var porez = (
                //    from f in frilensers
                //    where f.Procenat >= procenat
                //    select f.Zarada * procenat / 100
                //).Sum();

                if(porez > ukupanPorez)
                {
                    ukupanPorez = porez;
                }
            }

            Console.WriteLine(ukupanPorez);
        }
    }
}