Run ID | 作者 | 问题 | 语言 | 测评结果 | 时间 | 内存 | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
34324 | 小黑子(大鸡子的祖宗) | [acwing]首字母大写 | C++ | 编译错误 | 0 MS | 0 KB | 225 | 2024-01-06 17:08:26 |
#include <bits/stdc++.h> using namespace std; string s; int main(){ getline(cin,s); if(s[0]>='a'&&s[0]<='z'){ c=s[0]-'a'+'A'; s=s.erase(0,1); cout<<c+s; } else if(s[0]>='A'&&s[0]<='z'){ cout<<s; } }