你可能把题目的意思理解错了,而且字符类型的是%s,具体应该是
#include<stdio.h>
int main(){
char x;
scanf("%s",&x);
printf("%s %s %s",x-1,x,x+1);
printf("%d %d %d",x-1,x,x+1);
return 0;
}
?第6行不应该输出三个字符吗
自己看是否要处理输入A 和z 时的情况
#include <stdio.h>
#include <stdlib.h>
int main() {
int a ;
scanf("%c",&a);
printf("%c %c %c\n",a-1,a,a+1);
return 0;
}