Open your project folder and create a new file named hello.cpp . Paste a basic "Hello World" code:
Once MSYS2 is installed, a terminal window will open. You need to run a command to download the actual GCC compiler. download mingw compiler for vs code
Windows needs to know where the compiler lives so VS Code can find it. Open your project folder and create a new file named hello
Run the installer and follow the prompts. It is best to keep the default installation folder (usually C:\msys64 ). Step 2: Install the Compiler Toolchain Windows needs to know where the compiler lives
Under , find the Path variable and click Edit .
Visual Studio Code is a lightweight editor, not a full IDE. It doesn’t come with a compiler built-in. MinGW-w64 (Minimalist GNU for Windows) provides the essential GCC tools needed to transform your code into executable files. : No licensing fees or bulky software. Lightweight : Uses minimal system resources.
VS Code will compile the code, and the output will appear in the integrated terminal. 🚀 Are you trying to use a specific C++ version (like C++20)?