#include<bits/stdc++.h> using namespace std; int n; double a,b,s; int main(){ cin>>n; while(n--){ cin>>a>>b; s+=a*b; } s*=0.85; s*=10; s=int(s)*1.0/10; cout<<s; return 0; }