Learn C++23 by compiling it.

A guided course in modern C++ for complete beginners. Every step is a small program you run, check and tick off, so you always know where you stand.

Start lesson 1 Read the forum

hello.cpp
#include <print>
#include <string_view>

int main() {
    std::string_view lang = "C++23";
    std::print("Hello, {}!\n", lang);
}
g++ -std=c++23 hello.cpp && ./a.out
Hello, C++23!

The lessons

Lessons are published as they are written. Your ticks are saved as you go: in this browser for guests, on your account once you log in.

0 of 2 lessons complete

  1. 1. Your first C++ program

    Write, compile and run your first programs in the browser, store values in variables, format output, and learn to read the compiler's messages. No experience needed.

    0/7 checks
  2. 2. Types, auto and const

    Work with whole numbers, decimals, characters, true/false and text; see why the type decides the answer; let the compiler pick a type; and protect values with const.

    0/8 checks

Your progress is saved in this browser. Log in or create a free account to keep it across devices.

How a lesson works

  1. Read one step

    Each step introduces one new idea and explains every term the first time it appears.

  2. Compile the program

    Paste it into Compiler Explorer in your browser, or build it locally once your toolchain is set up.

  3. Tick the check

    Every step ends with an exact result to look for. When yours matches, tick it and move on.

Recent questions

No questions yet. If a check doesn't pass, post the code and the compiler's exact message.

Go to the forum