Run ID | Author | Problem | Lang | Verdict | Time | Memory | Code Length | Submit Time |
---|---|---|---|---|---|---|---|---|
37174 | chenyifei | 整理药名 | C++ | Wrong Answer | 0 MS | 244 KB | 366 | 2024-01-19 15:35:01 |
#include<iostream> #include<string> using namespace std; int main() { int n; cin>>n; string s; for(int i=1;i<=n;i++) { cin>>s; if(s[0]>='a'&&s[0]<='z') s[0]-=32; for(int j=1;j<=n;j++) if(s[j]>='A'&&s[j]<='Z') s[j]+=32; cout<<s<<endl; } return 0; }