About This Course

Get an idea of what we'll learn in this course.

Overview

This course provides recipes to help you get the most out of the C++ STL (Standard Template Library), including new features introduced with C++20.

C++ is a rich and powerful language. Built upon C, with syntactic extensions for type safety, generic programming, and object-oriented programming, C++ is essentially a low-level language. The STL provides a broad set of higher-level classes, functions, and algorithms to make your programming job easier, more effective, and less prone to error.

Press + to interact

Prerequisite knowledge

This course presumes that you have a basic understanding of C++, including syntax, structure, data types, classes and objects, templates, and the STL. The recipes and examples in this course presume that you understand the need to #include certain headers to use library functions. The recipes don’t usually list all the necessary headers, preferring to focus on the techniques at hand.

The C++20 standard

The C++ language is standardized by the International Organization for Standardization (ISO) on a roughly three-year cycle. The current standard is called C++20 (which was preceded by C++17, C++14, and C++11 before that). C++20 was approved in September 2020.

Press + to interact


C++20 adds many important features to the language and the STL. New features like
format, modules, ranges, and more will have a significant impact on the way we use the STL.

Intended audience

This course is for intermediate to advanced C++ programmers who want to get more out of the C++20 Standard Template Library. Basic knowledge of coding and C++ concepts are necessary to get the most out of this course.

Structure

Chapter 1, "New C++20 Features": Introduces the new STL features in C++20. This chapter aims to familiarize you with the new language features so you may use them with the STL.
Chapter 2, "General STL Features": Discusses modern STL features added in recent C++ versions.
Chapter 3, "STL Containers": Covers the STL's comprehensive library of containers.
Chapter 4, "Compatible Iterators": Shows you how to use and create STL-compatible iterators.
Chapter 5, "Lambda Expressions": Covers the use of lambdas with STL functions and algorithms.
Chapter 6, "STL Algorithms": Provides recipes for using and creating STL-compatible
algorithms.

Press + to interact


Chapter 7, "Strings, Stream, and Formatting": Describes the STL string and formatter classes.
Chapter 8, "Utility Classes": Covers STL utilities for date-and-time, smart pointers, optionals, and more.
Chapter 9, "Concurrency and Parallelism": Describes support for concurrency, including threads, async, atomic types, and more.
Chapter 10, "Using the File System": Covers the std::filesystem classes and how to put them to use with the latest advancements that came out with C++20.
Chapter 11, "A Few More Ideas": Provides a few more solutions, including a trie class, string split, and more. This provides advanced examples on how to put the STL to use for real-world problems.