c语言编译的时候为什么会出现应用程序错误 可以运行 输入数字就出现应用程序错误 新手请指教
代码如下#include<stdio.h>voidmain(){intscore;chargrade;printf("pleaseinputascore:");scanf...
代码如下# include <stdio.h>
void main()
{
int score;
char grade;
printf("please input a score:");
scanf ("%d",score);
if(score>=90)
{
grade='A';
}
if(score>=60&&score<=89)
{
grade='B';
}
if(score<60)
{
grade='C';
}
printf("%d belongs to %c",score,grade );
} 展开
void main()
{
int score;
char grade;
printf("please input a score:");
scanf ("%d",score);
if(score>=90)
{
grade='A';
}
if(score>=60&&score<=89)
{
grade='B';
}
if(score<60)
{
grade='C';
}
printf("%d belongs to %c",score,grade );
} 展开
2个回答
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询