Run ID 作者 问题 语言 测评结果 时间 内存 代码长度 提交时间
87418 sh25_zhangzh 输出亲朋字符串 C++ 通过 0 MS 244 KB 386 2026-04-17 15:13:15

Tests(1/1):


#include <iostream> #include <string> using namespace std; int main() { string s; cin>>s; string rest; int n=s.size(); for (int i=0;i<n;i++) { int a=s[i]; int b; if (i==n-1) { b=s[0]; } else { b=s[i+1]; } rest+=char(a+b); } cout<<rest<<endl; }


测评信息: