Skip to content

Commit b747c35

Browse files
April 2022 - Update 1
Many small improvements, several typos fixed, and flow refactoring, including: - Introduction: update references - Basic Concepts I: average computation reference, improved catastrofic cancellation, added compensation algorithms, added C++ standards compatibility note, moving implicit promotion, reorganized floating-point section - Basic III: parenthesis and brackets, better description for alignment in sizeof
1 parent 82419d0 commit b747c35

File tree

1 file changed

+40
-39
lines changed

1 file changed

+40
-39
lines changed

README.md

Lines changed: 40 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,8 @@
1-
# Modern C++ Programming #
1+
# Modern C++ Programming
2+
23
<img src="other/cpp_logo.png" />
34

4-
## C++11 / C++14 / C++17 / (C++20) ##
5+
## C++11 / C++14 / C++17 / (C++20)
56

67
This *open-access* course is directed at those who are already familiar with C and object-oriented programming towards a proficiency level of C++ programming. The course covers the basics of C++ programming and moves on to advanced C++ semantics and concepts.
78

@@ -18,27 +19,27 @@ If you enjoy the course or you find it useful, please add a **Star**
1819

1920
[![stars - Modern-CPP-Programming](https://img.shields.io/github/stars/federico-busato/Modern-CPP-Programming?style=social)](https://github.com/federico-busato/Modern-CPP-Programming)
2021

21-
## CHAPTERS ##
22-
23-
| | TITLE | MAIN FOCUS |
24-
| ------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
25-
| **1** | **[Introduction](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/01.Introduction.pdf)** | History of C/C++, Areas of Applications, Course introduction |
26-
| **2** | **[Basic Concepts I - Fundamental Types](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/02.Basic_Concepts_I.pdf)** | Integral data types, floating-point, operators, and conversion |
27-
| **3** | **[Basic Concepts II - Entities and Control Flow](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/03.Basic_Concepts_II.pdf)** | Enumerators, structures, control flow statements |
28-
| **4** | **[Basic Concepts III - Memory Management](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/04.Basic_Concepts_III.pdf)** | Heap, Stack, pointers, references, const property, conversion operators |
29-
| **5** | **[Basic Concepts IV - Functions and Preprocessing](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/05.Basic_Concepts_IV.pdf)** | Functions, lambda expressions, preprocessing directives |
30-
| **6** | **[C++ Object Oriented Programming I](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/06.Object_Oriented_I.pdf)** | Class hierarchy, constructor, destructor, class keywords |
31-
| **7** | **[C++ Object Oriented Programming II](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/07.Object_Oriented_II.pdf)** | Polymorphism, operators overloading |
32-
| **8** | **[C++ Templates and Meta-programming I](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/08.Templates_I.pdf)** | Function template, type traits |
33-
| **9** | **[C++ Templates and Meta-programming II](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/09.Templates_II.pdf)** | Class template, SFINAE |
34-
| **10** | **[Translation Units](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/10.Translation_Units.pdf)** | Dealing with multiple translation units and files, namespace |
35-
| **11** | **[Code Conventions](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/11.Code_Convention.pdf)** | Project organization and main code conventions |
36-
| **12** | **[Ecosystem](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/12.Ecosystem.pdf)** | Debugging, testing, building, documenting tools |
37-
| **13** | **[Utilities](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/13.Utilities.pdf)** | Main `std` libraries |
38-
| **14** | **[Containers, Iterators, and Algorithms](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/14.Iterators_Containers_Alg.pdf)** | Containers, iterators, algorithms |
39-
| **15** | **[Advanced Topics](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/15.Advanced_Topics.pdf)** | Move semantics, error handling, C++ idioms |
40-
| **16** | **[Optimization I](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/16.Optimization_I.pdf)** | Code optimizations, e.g. arithmetic, memory, etc. |
41-
| **17** | **[Optimization II](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/17.Optimization_II.pdf)** | Compiler optimizations, profiling and benchmarking tools |
22+
## CHAPTERS
23+
24+
| | TITLE | MAIN FOCUS |
25+
| ------ | ----------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------- |
26+
| **1** | **[Introduction](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/01.Introduction.pdf)** | History of C/C++, Areas of Applications, Course introduction |
27+
| **2** | **[Basic Concepts I - Fundamental Types](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/02.Basic_Concepts_I.pdf)** | Integral data types, floating-point, operators, and conversion |
28+
| **3** | **[Basic Concepts II - Entities and Control Flow](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/03.Basic_Concepts_II.pdf)** | Enumerators, structures, control flow statements |
29+
| **4** | **[Basic Concepts III - Memory Management](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/04.Basic_Concepts_III.pdf)** | Heap, Stack, pointers, references, const property, conversion operators |
30+
| **5** | **[Basic Concepts IV - Functions and Preprocessing](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/05.Basic_Concepts_IV.pdf)** | Functions, lambda expressions, preprocessing directives |
31+
| **6** | **[C++ Object Oriented Programming I](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/06.Object_Oriented_I.pdf)** | Class hierarchy, constructor, destructor, class keywords |
32+
| **7** | **[C++ Object Oriented Programming II](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/07.Object_Oriented_II.pdf)** | Polymorphism, operators overloading |
33+
| **8** | **[C++ Templates and Meta-programming I](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/08.Templates_I.pdf)** | Function template, type traits |
34+
| **9** | **[C++ Templates and Meta-programming II](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/09.Templates_II.pdf)** | Class template, SFINAE
35+
| **10** | **[Translation Units](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/10.Translation_Units.pdf)** | Dealing with multiple translation units and files, namespace |
36+
| **11** | **[Code Conventions](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/11.Code_Convention.pdf)** | Project organization and main code conventions |
37+
| **12** | **[Ecosystem](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/12.Ecosystem.pdf)** | Debugging, testing, building, documenting tools |
38+
| **13** | **[Utilities](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/13.Utilities.pdf)** | Main `std` libraries |
39+
| **14** | **[Containers, Iterators, and Algorithms](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/14.Iterators_Containers_Alg.pdf)** | Containers, iterators, algorithms |
40+
| **15** | **[Advanced Topics](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/15.Advanced_Topics.pdf)** | Move semantics, error handling, C++ idioms |
41+
| **16** | **[Optimization I](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/16.Optimization_I.pdf)** | Code optimizations, e.g. arithmetic, memory, etc. |
42+
| **17** | **[Optimization II](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/17.Optimization_II.pdf)** | Compiler optimizations, profiling and benchmarking tools |
4243

4344
## TOPICS
4445

@@ -56,39 +57,39 @@ If you enjoy the course or you find it useful, please add a **Star**
5657
* **Hello World**: I/O Stream
5758
* **C++ Fundamental Types Overview**: Arithmetic types, Non-standard arithmetic types, `void` type, Pointer type and `nullptr`
5859
* **Conversion Rules**
60+
* **`auto` declaration**
5961
* **C++ Operators**: Operators precedence, Prefix/Postfix increment/decrement, Assignment, Compound , and comma operators, Spaceship operator `<=>`
60-
* **Integral Data Types**: Fixed width integers, When use signed/unsigned integer? Promotion, Truncation, Undefined behavior
61-
* **Floating-point Types and Arithmetic**: Normal/Denormal values, Not a Number (`NaN`), Infinity, Properties
62-
* **Floating-point Issues**: Floating-point comparison, Catastrophic cancellation
62+
* **Integral Data Types**: Fixed width integers and `size_t`, When use signed/unsigned integer? Promotion, Truncation, Undefined behavior
63+
* **Floating-point Types and Arithmetic**: Normal/Denormal values, Infinity, Not a Number (`NaN`), Summary, Properties
64+
* **Floating-point Issues**: Catastrophic cancellation, Floating-point comparison
6365

6466
**[3. Basic Concepts II - Entities and Control Flow](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/03.Basic_Concepts_II.pdf)**
6567

6668
* **Enumerators**
67-
* **`struct`, `union`, and Bitfield**
68-
* **`using`, `decltype`, and `auto`**
69-
* **Control Flow**: `if` Statement, `for` Loop, `switch`, `goto`
69+
* **`struct`, Bitfield, `union`
70+
* **Control Flow**: `if` Statement, `for` Loop, Range-base `for` loop, `switch`, `goto`
7071

7172
**[4. Basic Concepts III - Memory Management](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/04.Basic_Concepts_III.pdf)**
7273

7374
* **Heap and Stack**: Stack Memory, `new`, `delete`, Memory Leak
74-
* **Initialization**: Variable initialization, Uniform initialization, Structure initialization, Fixed-size array initialization, Dynamic array initialization
75-
* **Pointers and References**: Pointer, Address-of operator `&`, Reference
75+
* **Initialization**: Variable initialization, Uniform initialization, Fixed-size array initialization, Structure initialization, Dynamic array initialization
76+
* **Pointers and References**: Pointer Operations, Address-of operator `&`, Reference
7677
* **`const`, `constexpr`, `consteval`, `constinit`**
7778
* **Explicit Type Conversion**: `static_cast`, `const_cast`, `reinterpret_cast`, Type punning
7879
* `sizeof` Operator
7980

8081
**[5. Basic Concepts IV - Functions and Preprocessing](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/05.Basic_Concepts_IV.pdf)**
8182

8283
* **Declaration and Definition**
83-
* **Functions**: Pass by-value, Pass by-pointer, Pass by-reference, Overloading, Default parameters, Attributes
84+
* **Functions**: Pass by-value, Pass by-pointer, Pass by-reference, Function signature and Overloading, Default parameters, Attributes
8485
* **Function Objects and Lambda Expressions**: Function pointer, Function object (or Functor), Capture list, Other features, Capture list and classes
8586
* **Preprocessing**: Preprocessors, Common errors, Useful macro, Stringizing operator (`#`), `#pragma` and `#error`, Token-Pasting Operator (`##`), Variadic Macro
8687

8788
**[6. C++ Object Oriented Programming I](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/06.Object_Oriented_I.pdf)**
8889

89-
* **C++ Classes**
90+
* **C++ Classes**: RAII Idiom
9091
* **Class Hierarchy**: Access specifiers, Inheritance access specifiers
91-
* **Class Constructor**: Default constructor, Initializer list, Uniform initialization, Delegate constructor, `explicit` keyword
92+
* **Class Constructor**: Default constructor, Class initialization, Uniform initialization, Delegate constructor, `explicit` keyword
9293
* **Copy Constructor**
9394
* **Class Destructor**
9495
* **Defaulted Members** (`= default`)
@@ -98,7 +99,7 @@ If you enjoy the course or you find it useful, please add a **Star**
9899

99100
* **Polymorphism**: `virtual` methods, Virtual table, `override` keyword, `final` keyword, Common errors, Pure virtual method, Abstract class and interface
100101
* **Inheritance Casting and Run-time Type Identification**
101-
* **Operator Overloading**: Overview, Subscript operator `[]`, Comparison operator `<`, Spaceship operator `<=>` Function call operator `()`, Conversion operator `T()`, Increment and decrement operators `++`/`--`, Assignment operator `=`, Stream operator `<<`, Operator Notes
102+
* **Operator Overloading**: Overview, Subscript operator `[]`, Comparison operator `<`, Spaceship operator `<=>` Function call operator `()`, Conversion operator `T()`, Return type overloading resolution, Increment and decrement operators `++`/`--`, Assignment operator `=`, Stream operator `<<`, Operator Notes
102103
* **C++ Special Objects**: Aggregate, Trivial class, Standard-layout class, Plain old data (POD), Hierarchy
103104

104105
**[8. C++ Templates and Meta-programming I](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/08.Templates_I.pdf)**
@@ -108,7 +109,7 @@ If you enjoy the course or you find it useful, please add a **Star**
108109
* **Type Traits**: Overview, Type traits library, Type manipulation, Type relation and transformation
109110
* **Template Parameters**: Overview, Special cases
110111

111-
**[9. C++ Templates and Meta-programming II](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/9.Templates_II.pdf)**
112+
**[9. C++ Templates and Meta-programming II](https://github.com/federico-busato/Modern-CPP-Programming/blob/master/09.Templates_II.pdf)**
112113

113114
* **Class Template**: Class specialization, Class + Function - specialization, `friend` keyword, Dependent names, Template variable
114115
* **Template Meta-Programming**
@@ -219,17 +220,17 @@ If you enjoy the course or you find it useful, please add a **Star**
219220
2. Software Design Chapter
220221
3. Build Aspects Chapter (e.g. reducing build time)
221222

222-
### Essential Tool ###
223+
### Essential Tool
223224

224225
Online compiler and execution: [CompilerExplorer](https://godbolt.org/)
225226

226227
* for code execution: [Add new..] -> [execution only]
227228

228-
### Reporting bugs and contributing ###
229+
### Reporting bugs and contributing
229230

230231
If you find any typos, conceptual errors, or sections to improve, please report them by writing directly to me or by using the `issue` panel
231232

232-
## Author ##
233+
## Author
233234

234235
`Federico Busato`
235236

0 commit comments

Comments
 (0)