69,371
社区成员
发帖
与我相关
我的任务
分享
#include<stdio.h>
#include<stdlib.h>
#include <ctype.h>
int main()
{
int i;
char str[16];
scanf("%s", str);
for (i = 0; str[i]; i++)
if (isupper(str[i]))
str[i] = 'A' + (str[i] - 'A' + 4) % 26;
else if (islower(str[i]))
str[i] = 'a' + (str[i] - 'a' + 4) % 26;
puts(str);
return 0;
}