Run ID Author Problem Lang Verdict Time Memory Code Length Submit Time
36188 lnx 凯撒密码 C++ Wrong Answer 1 MS 240 KB 349 2024-01-10 12:12:37

Tests(0/2):


#include<iostream> #include<cstdio> #include<cstdlib> #include<cstring> #include<string> using namespace std; int main() { char ch[100]; int n; cin>>ch>>n; int length=strlen(ch); for(int i=0;i<=length;i++) { int tmp=(int)ch[i]; tmp+=n; if(tmp>122) { tmp-=26; } ch[i]=(char)tmp; } cout<<ch; return 0; }


Judgement Protocol: