下面这段代码是让计算机读入一个字符并把这个字符原样输出。其中有3个错误,快来改正吧!
修改后:
#include <stdio.h>
#include <stdlib.h>
int main( )
{
char a;
scanf("%c", &a);
printf("%c", a);
system("pause");
return 0;
}
运行效果:
下面这段代码是让计算机读入一个字符并把这个字符原样输出。其中有3个错误,快来改正吧!
修改后:
#include <stdio.h>
#include <stdlib.h>
int main( )
{
char a;
scanf("%c", &a);
printf("%c", a);
system("pause");
return 0;
}
运行效果: