| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 74753 | LJY | 情报加密 | C++ | Presentation Error | 0 MS | 276 KB | 525 | 2024-05-25 21:54:39 |
#include <iostream> using namespace std; int main() { string s; getline(cin, s); string result = " "; for (int i = 0; i < s.length(); i++) { char c = s[i]; if ((c >= 'a' && c < 'z') || (c >= 'A' && c < 'Z')) { result += char(c + 1); } else if (c == 'z') { result += 'a'; } else if (c == 'Z') { result += 'A'; } else { result += c; } } cout << result << endl; return 0; }