【问题标题】:How to compile c++ in vs code?如何在vs代码中编译c++?
【发布时间】:2021-01-05 03:31:46
【问题描述】:

您好,我是 C++ 的初学者,我试图在 vs 代码中编译一些代码,但我收到了这个错误:'g++' 不被识别为内部或外部命令, 可运行的程序或批处理文件。 我只是想知道如何解决这个问题,每当我尝试在命令行中编译时都会遇到类似的错误?

【问题讨论】:

标签: c++ visual-studio-code


【解决方案1】:

首先,你需要安装一个编译器(MinGW)。

Now RightClick on My Computer
goto Advanced System Settings 
Environment Variables
now there in system variable goto path
in that add the file location of MinGW\bin folder
save it and restart VScode

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2015-01-21
    • 2022-01-09
    • 1970-01-01
    • 2021-01-03
    • 1970-01-01
    • 2023-02-23
    • 1970-01-01
    相关资源
    最近更新 更多