Vc++6.0 c语言程序,求解惑

img


要求根据输入的科一到科四的成绩,判断是否能够取得驾照。
使用vc++6.0可以运行

定义四个变量分别表示科目一到科目四的成绩,然后通过if语句判断是否满足取得驾照的条件。

#include<stdio.h>
int main()
{
    int score1,score2,score3,score4;
    scanf("%d%d%d%d",&score1,&score2,&score3,&score4);
    if(score1>=90&&score2>=80&&score3>=90&&score4>=90)
       printf("可以取得驾照\n");
    else
       printf("不可以取得驾照\n");
    return 0;
}

#include <stdio.h>
int score_1,score_2,score_3,score_4
int main()
{
  if(score_1>=90 & score_2>=80 & score_3>=90 & score_4>=90){
  printf("sucess")
}else{
  printf("failed")
}
   
   return 0;
}