Classes/Structs
The basic types provided by C++ are a great starting point, but it's rare that these are the only variable types you'll need within an application. When we're representing real-world information, such as user records or the various properties of an object, we often need more complex data types to store our information. C++ allows us to create such types in classes and structs. Classes are going to be covered in greater detail in a later chapter, but for now, we're going to simply introduce a number of key concepts.
Classes
A class is a collection of variables and functionality, encapsulated neatly within a single object. When we define a class, we're creating a blueprint for that object. This means that every time we want to create an object of that type, we use that blueprint to construct our object. Classes are a core part of C++; after all, C++ was originally named C with Classes.
Members (variables and functions) declared in a C...