Run ID | Author | Problem | Lang | Verdict | Time | Memory | Code Length | Submit Time |
---|---|---|---|---|---|---|---|---|
40910 | DUANZHIBO | 字符串改成大写, 逆序输出 | C++ | Accepted | 1 MS | 248 KB | 227 | 2024-02-18 11:12:24 |
#include<bits/stdc++.h> using namespace std; int main() { char a[110]; cin>>a; for(int i=0;i<strlen(a);i++){ if(a[i]>='a'&&a[i]<='z')a[i]-=32; } for(int i=strlen(a)-1;i>=0;i--){ cout<<a[i]; } return 0; }