提交时间:2023-08-09 17:09:49

运行 ID: 81618

#include<bits/stdc++.h> using namespace std; int n,make,eat,ans,mine=114514; int main(){ cin>>n; for(int i=1;i<=n;i++){ cin>>make>>eat; ans+=make; mine=min(eat,mine); } cout<<ans+mine; return 0; }