Installation Overview
This page explains how to set up your computer (or your pool account) for programming in C/C++. You need:
- a C/C++ compiler – we use GCC (on macOS the compatible Clang),
- an editor – we use Visual Studio Code.
Both programs must be installed first. Start with the installation guide for your system. Afterwards, you need to set up Visual Studio Code. If you run into problems, first check the FAQ of the guide that applies to you and the general FAQ, or ask your tutors.
1. Installing GCC and Visual Studio Code
Which guide do I need?
| Your device | Guide |
|---|---|
| Your own laptop with Windows (Intel or AMD processor, "x64") | Windows, section 1a |
| Your own laptop with Windows on ARM (e.g. Surface Pro X, laptop with Snapdragon processor) | Windows, section 1b |
| Your own Mac (Intel or Apple chip M1, M2, …) | macOS |
| Your own laptop with Linux | Linux |
| TUHH pool computer running Windows | Windows pool |
| TUHH pool computer running Linux | Linux pool |
| Tablet or smartphone (iOS, Android) | Not suitable for programming – use a pool computer and talk to your tutors. |
How do I find out whether my Windows computer is x64 or ARM?
- Open
Settings(Windows key +I). - Select
Systemand thenAboutat the very bottom (German:Info). - Under
System type(German:Systemtyp) it says eitherx64-based processor(→ section 1a) orARM-based processor(→ section 1b).
Note
If you use Windows on ARM and run into problems during the installation, we are happy to help you in the tutorial.
All guides
Private computers
Pool computers
2. Setting up Visual Studio Code
Note
Please complete the installation guide that applies to you first before continuing with this step!
- Start Visual Studio Code.
- Select a new folder. For example,
~/InfIng/Projekte/setupon Linux orH:\My Documents\InfIng\Projekte\setupon Windows. - Confirm that you trust the authors (
Yes, I trust the authors). - Create and open a new file
main.cpp. - A pop-up asks:
Do you want to install the recommended extensions for C++?Confirm withInstall. - After the installation, open the file again.
- Click the play button in the top right corner.
- Select the
Detected Taskoption with your compiler, e.g.Detected Task (compiler: /usr/bin/g++)on Linux and macOS orDetected Task (compiler: C:\msys64\ucrt64\bin\g++.exe)on Windows.
FAQ and problems
If you run into problems, please first check the FAQ of the guide that applies to you and the general FAQ.