C++ 代码
#include <iostream>
#include <cstring>
using namespace std;
int total=0;
int y;
int main() {
ios::sync_with_stdio(false);
int n;
cin>>n;
while(n--){
int w,s;
cin>>w>>s;
total+=w*s;
}
y= (total >0) ? total:0;
cout<<y;
return 0;
}
冰川哥牛的