1 条题解
-
0
C++ :
#include <iostream> #include <cstdio> #include <cstring> using namespace std; const int N = 100010; int main(){ string s[101] , tmp; int n; cin >> n; for(int i = 1 ; i <= n ; ++i) cin >> s[i]; for(int i = 1 ; i <= n ; i++){ tmp = s[i]; if(tmp[0] >= 'a' && tmp[0] <= 'z') tmp[0] = tmp[0] - 32; for(int j = 1 ; j < tmp.size() ; j++){ if(tmp[j] >= 'A' && tmp[j] <= 'Z') tmp[j] = tmp[j] + 32; } s[i] = tmp; } for(int i = 1 ; i <= n ; i++) cout << s[i] << endl; return 0; }
- 1
信息
- ID
- 456
- 时间
- 1000ms
- 内存
- 128MiB
- 难度
- (无)
- 标签
- 递交数
- 0
- 已通过
- 0
- 上传者