C++ Story

S R T B H P N

C++ Story:

Prologue
This C++ Story pulls together site pages, presentations on C++ syntax and semantics, and example code to present a brief tutorial on the C++ programming language. Also provided are exercises to test your skills. The story consists of chapters on: basics of C++ syntax and semantics, classes, class relationships and their use to build compound objects, templates and template metaprogramming. The story concludes with a description of a few of the standard libraries, libraries provided with this site, and a few third-party libraries.
Models
Chapter 1 introduces models for building and executing C++ programs, for memory layout, classes, and templates.
Survey
Chapter 2 provides a gentle survey of the C++ language and its libraries. Each of the topics covered here are discussed in much more detail in subsequent chapters.
Data
Chapter 3 - Data discusses Types, Explores their meaning and structure. That is followed by a summary of modern casts. Then, some new types added to the standard library are briefly discussed. Data initialization is presented with examples followed by an example of structured binding. The Chapter concludes with a discussion about assembling complex data structures using the STL containers as building blocks.
Operations
Chapter 4 - Operations is concerned with functions, methods, functors, and lambdas. It presents information about passing parameters and return values including a brief discussion of return value optimization. The chapter concludes with a quick survey of the STL algorithms and Testing.
Classes
C++ is a relatively strongly typed language, favoring error detection at compile time over run-time. The fundamental (built-in) types are simple, similar to those of other languages like C# and Java. Those are augmented with a very effective set of library-defined types. Most of the chapter is devoted to the process of building user-defined types with classes and structs. Here, we emphasize the construction of value types. This is consolidated with a discussion of typical class anatomy for value types.
Class Relships
C++, like many object oriented languages, provides four fundamental class relationships: inheritance, composition, aggregation, and using. To those C++ adds the friend relationship. The chapter focuses on compound objects, their memory layout, construction, and polymorphic operations within inheritance hierarchies. The chapter concludes with a couple of examples.
Templates
Templates are the C++ mechanism to provide generic processing. Chapter 6. - Templates discusses template functions with overloading and template classes with specialization. A lot of the focus of this chapter is on overload resolution and template type deduction. Several examples are presented for each of these topics.
TemplateMetaprog
Implementing templates required C++ to develop a functional language used by the compiler to provide template functions and classes. Template metaprogramming is concerned with writing code in that functional language to provide features that essentially extend the language in ways useful for creation of applications. A lot of this requires some significant skill and effort, but provides long-lasting rewards through reuse.
Libraries
Chapter 9. - Libraries is now a blank sheet waiting to be filled. There is a lot of information in the code repositories that will be examined here, along with the standard libraries.
Streams
Chapter 10. - Libraries is now a blank sheet waiting to be filled. There is a lot of information in the code repositories that will be examined here, along with the standard libraries.
STL
Chapter 11. - Libraries is now a blank sheet waiting to be filled. There is a lot of information in the code repositories that will be examined here, along with the standard libraries.
Interesting
Chapter 12. - Other Interesting Topics is, now, a collection of links. I intend to expand and annotate each link category.