20分求助
查看原帖
20分求助
773371
Dreeick楼主2022/11/5 18:30
#include <bits/stdc++.h>

using namespace std;

int main(){
	string s;
	while(cin >> s){
		for(unsigned short i = 0;i < s.length();i += 2){
			s[i] = toupper(s[i]);
		}
		for(unsigned short i = 1;i < s.length();i += 2){
			s[i] = tolower(s[i]);
		}
		cout << s << ' ';
	}

	return 0;
}

只有前两个点AC,后面的都是TLE

难道是我太蒻了吗
2022/11/5 18:30
加载中...