C++ Course
(The System Programming course given at VUB in the academic year 2018-2019, 2019-2020, 2020-2021, 2021-2022)
(The System Programming course given at VUB in the academic year 2018-2019, 2019-2020, 2020-2021, 2021-2022)
This course is designed as a fast-paced introduction to C++ programming language being intended for students with a good degree of hardware awareness and moderate previous programming experience (e.g. Java and Matlab). C++ is a general purpose programming language that supports generic computer programming models. By practical training on Microsoft Visual Studio, which is the common integrated development environment (IDE) popular on Windows operating systems, students are exposed to practical programming problems and their solutions. The students will be given examples written in ANSI/ISO standard C++, and gain transferable knowledge for other programming domains (e.g. programming with third-party libraries).
Recommended resources:
Liberty, Jesse, and Bradley L. Jones. Sams teach yourself C++ in 21 days. Sams Publishing, 2004.
Meyers, Scott. Effective modern C++: 42 specific ways to improve your use of C++ 11 and C++ 14. " O'Reilly Media, Inc.", 2014.
Meyers, Scott. Effective STL: 50 specific ways to improve your use of the standard template library. Pearson Education, 2001.
Meyers, Scott. Effective C++: 55 specific ways to improve your programs and designs. Pearson Education, 2005.
Content
This course introduces C++ programming and teaches a number of concepts in computer science, of variables, pointers & streams, control structures, vectors, functions, classes, objects and some good coding practices including debugging techniques and avoiding common programming errors.
Essentially, this is a short “hands-on” course, during which the students will attend ten hours of intensive lectures (HOC: 10h), ten hours of practical sessions (WPO: 10h) and will prepare an elaborated individual C++ project (ZELF: 45h).
The outline of this course is given next:
1. C++ language fundamentals
1.1 What is C++?
1.2 C++ and object oriented programming
1.3 Hello world!
1.4 Working with variables, constants, enumerated constants
1.5 Creating expressions and statements
1.6 Conditional commands
1.7 Organizing into functions
1.8 Loops
2. Working with advanced functions
3. Understanding pointers
4. Function templates
5. Standard template library (STL)
5.1 Containers and error handling
5.2 Algorithms
5.3 Lambda functions
6. Classes
6.1 Constructors
6.2 Copy assignment
6.3 Destructor
6.4 Static variables and members
7. Inheritance
7.1 Overriding
7.2 Polymorphism
7.3 Virtual functions
7.4 Virtual destructor
7.5 Inheritance specifiers
7.6 Const functions
8. Interface and abstract classes
9. Smart pointers
10. Creating and connect a dynamic link library to a Qt project
11. Efficient C++ programming
11.1 Header guards
11.2 Invoking third-party libraries (e.g. Boost)
11.3 Reading and writing files
11.4 Parsing strings
11.5 Converting data types
11.6 Working with paths
11.7 Serialization and de-serialization
11.8 Regular expression
12. Qt GUI
12.1 Meta-object compiler
12.2 Signal and slots
13. Thread programming
13.1 Data race
13.2 Mutex, atomic, condition variables
This lecture covers the following topics:
Project definition
What is C++?
C++ and OOP
Hello World!
Visual studio
Variables
Constants
Enumerated constants
This lecture covers the following topics:
Expressions
The if-else statement
The conditional operator
The switch Statement
Functions
Recursive functions
Loops
Function parameters and arguments
This lecture covers the following topics:
The solutions to the given exercises
Function parameters and arguments
Pointers
Memory
Function templates
This lecture covers the following topics:
Function templates (exercise)
Template Specialization
Standard Template Library (STL)
Containers
error handling
Algorithms
Lambda functions
Smart pointers
Header guards
Boost library
This lecture covers the following topics:
Solutions to the given exercises
Read/write files and parsing strings
Regular expressions
Classes
Constructors
Copy assignment
Destructor
Exercise
How to add boost library to a project created by Visual Studio?
This lecture covers the following topics:
Classes
Static variables and members
The solution to the exercise
Your questions
Inheritance
Overriding
Polymorphism
Virtual functions
Virtual destructor
This lecture covers the following topics:
Inheritance
Inheritance specifiers
Const functions
Multiple and Virtual inheritance
Interface and abstract classes
DLL and Qt project
This lecture covers the following topics:
Qt GUI
Meta-object compiler
Signals and slots
A Qt project (showed in the class)
Threads
Your questions about Qt and your final project
This lecture covers the following topics:
Threads
Data race
Mutex, atomic, condition variables
A Qt project (showed in the class)
A review over object-oriented programming
What should be sent as your final project?