#include <stdio.h>

int main() { char input; printf("请输入一个大写字母:"); scanf("%c", &input);

// 判断输入是否为大写字母
if (input >= 'A' && input <= 'Z') {
    // 将大写字母转换为小写字母,并加上2得到输出字母
    char output = (input - 'A' + 2) % 26 + 'a';
    printf("输出的字母为:%c\n", output);
} else {
    printf("输入不是大写字母\n");
}

return 0;

}


原文地址: http://www.cveoy.top/t/topic/iRL2 著作权归作者所有。请勿转载和采集!

免费AI点我,无需注册和登录