1.4: Download and Install App for C++ Programming (PC Users)

Introduction to Programming with C++ · LibreTexts

0%

Contents

    Text

    Size
    100%
    Theme
    Typeface
    Line length
    Spacing

    Read aloud

    How

    Speed: 1×
    Light up
    Highlight

    Symbols: Mulberry Symbols, © 2018–2026 Steve Lee, CC BY-SA 4.0 (licence, the set), the site's own copies.

    From LibreTexts, under CC BY-NC-SA 4.0, as the source states it; its equations are written in TeX, which the PDF shows typeset. This page at LibreTexts.

    1.4: Download and Install App for C++ Programming (PC Users)

    Step 1: Go to https://visualstudio.microsoft.com/downloads

    You will see following screen:

    Image 1-4-1.png

    Select "Community" version, and click on "Free download".

    Step 2: Go to the Download Folder in your computer and run the following installer:

    VS4-1.jpg

    Double click on "VisualStudioSetup" in the Download Folder, in the following box, click on "Continue":

    VS5.jpg

    In following pop up window, check "Desktop development with C++", and leave the rest of boxes unchecked. Then click on "Install"

    VS6-1.jpg

    The installation process begins:

    Installing-1.png

    In the following window, click on OK and then restart your computer:

    Completed.png

    Congratulations! You have successfully installed Microsoft Visual Studio on your computer and ready to use it for coding a C++ program.

    Get Started with Microsoft Visual Studio

    Now, let's use the IDE we just installed to write, build, and run a simple C++ program.

    If you prefer watching video presentations for this topic, please study following video lecture:

    Video Presentation 1.1 Getting Started with Microsoft Visual Studio

    This video lecture is based on Community 2019, which is very similar to Community 2022

    If you prefer the text and graphical presentation, please proceed.

    Step 1: Go to Start on your computer and launching the app (Now, it is Visual Studio 2026)

    VS7.png

    After the app is launched, we will see following screen (now it is Visual Studio 2026):

    R1.png

    Step 2: Click on "Create a new project, then following screen appears:

    R2.png

    Step 3: Select "Empty Project" and then click on "Next". Now, following screen shows up:

    R3.png

    Step 4: Name your project (here I name my project as "myProject"). Please pay attention to the default location where the project is saved. You may change it to the location where you prefer such as "Desktop". Then click on "Create". We will see following screen:

    R4.png

    Step 5: Right click on "Source Files", then select "Add" and then select "New Items..." as shown below:

    R5.png

    Now, a blank file is opened, and this is where we will write our C++ programs:

    R7.png

    Step 6: Key in the code of a simple C++ program as shown below:

    R8.png

    This program will display a message "Good Morning!" on the output screen of the program. A C++ program need to be built before it can be executed. When we say "Build a program" it means error-checking and linking all the computer resources which are required for the program to run.

    Step 7: Click on "Build" and then select "Build Solution" as shown below:

    R9.png

    If there is no errors found, we should see following screen with those highlighted words:

    R10.png

    Now we are ready to execute the program.

    Step 8: Click on "Debug" and then select "Start Without Debugging" as shown bellow:

    R11.png

    Now, the program is being executed and an output window shows up. The message "Good Morning!" appears in the window:

    R12.png

    Congratulations! You just successfully wrote, built, and ran a C++ program with the IDE.


    This page titled 1.4: Download and Install App for C++ Programming (PC Users) was last modified on Wed, 24 Dec 2025 20:37:22 GMT and is shared under a CC BY-NC-SA 4.0 license and was authored, remixed, and/or curated by Jin He.