Why C++?
Let's begin by exploring some of the reasons for using C++ today. In short, C++ is a highly portable language that offers zero-cost abstractions. Furthermore, C++ provides programmers with the ability to write and manage large, expressive, and robust code bases. In this section, we'll look at what we mean by zero-cost abstractions, compare C++ abstraction with abstraction in other languages, and discuss portability and robustness, and why such features are important.
Let's begin by getting into zero-cost abstractions.
Zero-cost abstractions
Active code bases grow. The more developers working on a code base, the larger the code base becomes. In order to manage the growing complexity of a code base, we need language features such as variables, functions, and classes to be able to create our own abstractions with custom names and interfaces that suppress details of the implementation.
C++ allows us to define our own abstractions but it also...