0分全WA求助
查看原帖
0分全WA求助
1288602
Xianyujunzhu楼主2024/4/14 15:33
#include<bits/stdc++.h>
using namespace std;
int main(){
	int N;
	cin>>N;
	int maxx=-1,s;
	char str[25],maxstr[25];
	for(int i=1;i<=N;i++){
		cin>>s;
		cin.get(str,21);
		if(s>maxx){
			maxx=s;
			strcpy(str,maxstr);
		}
	}
	cout<<maxstr;
	return 0;
}
2024/4/14 15:33
加载中...