Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
102854 | 杨登博 | 大力水手吃蔬菜 | C++ | Accepted | 1 MS | 268 KB | 377 | 2024-12-23 20:58:42 |
#include<iostream> // cin\cout\endl #include<cstdio> //scanf()\printf() #include<cstring> // strcpy()\strcat()\strcmp()\strlen()\memset() using namespace std; int main(){ int d,p,m,n=9999,sun=0; cin>>m; for(int i=1;i<=m;i++){ cin>>d>>p; if(p<n){ n=p; } sun+=n*d; } cout<<sun; return 0; }