Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
114033 张智博 元音字母转换 C++ Wrong Answer 1 MS 272 KB 527 2025-03-18 21:48:03

Tests(0/1):


Code:

#include <iostream> #include <string> using namespace std; int main() { int T; cin >> T; // 输入测试数据的个数 cin.ignore(); // 忽略换行符 while (T--) { string str; getline(cin, str); for (char &c : str) { if (c == 'a' || c == 'e' || c == 'i' || c == 'o' || c == 'u') { c = toupper(c); } else { c = tolower(c); } } cout << str << endl; } return 0; }


Run Info:

------Input------
20 aeiou AEIOU QWERTYUIOPasdfghjklZXCVBNMqwertyuiopASDFGHJKLzxcvb a e i o u A E I O U AaEeIiOoUu python java mysql eClIPse PHP cPp
------Answer-----
AEIOU AEIOU qwErtyUIOpAsdfghjklzxcvbnmqwErtyUIOpAsdfghjklzxcvb A E I O U A E I O U AAEEIIOOUU pythOn jAvA mysql EclIpsE php cpp
------Your output-----
AEIOU aeiou qwertyuiopAsdfghjklzxcvbnmqwErtyUIOpasdfghjklzxcvb A E I O U a e i o u aAeEiIoOuU pythOn jAvA mysql EclipsE php cpp