为什么 VScode 在这段代码中显示错误?

问题描述 投票:0回答:1

VScode shows that there exist 2 errors in this program

我尝试通过输入“gcc add.c”在终端中运行此文件,但它返回错误“ld returned 1 exit status”。除了 VScode 之外,我没有在其他任何地方打开该文件

c compiler-errors
1个回答
0
投票
#include <stdio.h>

int main()
{
   int a,b;
    printf("Enter number a:");
    scanf("%d", &a);
    printf("Enter number b:");
    scanf("%d", &b);

    return 0;
}
© www.soinside.com 2019 - 2024. All rights reserved.