These course explain the C++ language from its basics up to the newest features introduced by C++11. Chapters have a practical orientation, with example programs in all sections to start practicing what is being explained right away.
Best Course Studies in Engineering & Technology in Ukraine 2017.
What is a computer, computer command, an application and a programming language? The evolution of these notions.
Computer program execution detailed analysis: describing roles of operating system, drivers, CPU, memory, bus, keyboard, mouse, and other components
The differences between high and low level programming languages (machine code, assembler, C, C++, Java, SQL, HTML).
How to start to write a program. Text editor, compiler, linker.
IDEs (Integrated Development Environments).
Explanation of previous program code line-by-line.
The preprocessor - program entry point.
Introducing first coding rules. Errors, how to deal with them.
Data types (size, range), declaration of variables. Naming rules, code readability and good coding style.
The stack (LIFO queue). Variables visibility and life duration. Global and local variables. Bad coding style - using global variables. Visibility extension operator “::”.
Variables and constants, a difference between initialization and assignment.
Binary, decimal and hexadecimal formats.
"Hello world!" program.
How to receive data from user input and show it. User dialog.
The first tools:
The notions of operator, expression and instruction. Correct terminology usage importance for successful interview passing.
Arithmetic operators, comparison operators and rules of their usage. Signed and unsigned types. Explicit and implicit type cast. Post- and preincrement. Priority and associativity. Conditional operators (if, else if), ternary operator, switch (fall through concept).
Loops: for, while, do while. Nested loops (i,j,k counters order).
Debug: How to trace a program execution, breakpoints, F5, F10, watches.
A few questions from the interviews.
A simple calculator. Examine the ability to process any user input.
How to reduce the number of possible errors. The first design concept of cross-platform application.
Shapes drawing: filled, empty, with defined borders thickness, rectangles, triangles, rhombus.
How to display text in the middle of the rectangle. Screen positioning
Several shapes in a row.
Simple animations (moving shapes), getch(), the first tool to obtain required information.
Find and process specific numbers in the range.
The first program 'Drawing', which could work eternal; it must show menu, draw any shape by user's choice or terminate.
Arrays, pointers, references, algorithms:
Stack based array, its size, index, sizeof () operator, array initialization.
Pointers, how does iArray[i] expression actually works, what means the pointer type for a compiler. Dynamic memory allocation, heap, new, delete, delete operators. All pointers related nuances: uninitialized pointers, hanged (forgotten) pointers, memory leaks (and tools to detect it). Pointer to everything - void *.
References, differences between them and pointers.
Sort, search and comparison algorithms, their performance. The profiler. Compile and runtime errors.
Dynamic arrays (that can change size at runtime). Multidimensional arrays. -
Algorithms: search, search minimum value, maximum value, count items, sum, average.
More complicated algorithms: work with multidimensional arrays, histogram creation, matrix rotation. How to look ahead from the current position in array.
Several sorting algorithms with analysis of their performance.
First game: tick-tack-toe. Description: User will have option to choose '0'-s or 'X'-s and set how much rounds to play. The program should determine the winner of current round and keep the total number of wins, draws and defeats.
Program also should be protected from user's errors (with explanation of them), have a good usability and interface. Advanced: use color for text output.
Why do we need in functions?
Passing function arguments by value, by address and by reference.
First look at the application address space, and executable file format, a cost of the function call.
Functions overloading, default parameters.
Recursion, call stack, stack overflow, integer overflow.
Pointers and const modifier: a difference between constant pointer and pointer to constant.
A good coding style. Why it is so important.
Algorithm performance measurement. How to get reasonable accuracy.
Some tasks from interview (recursion usage).
Rewrite Tick_tack-toe, Calculator and Drawing applications using functions.
A console application, system buffer and keyboard interrupts.
Library functions: strcmp, strlen, strtok_s, strstr.
How to format text output (in c and c++), cin.getline.
char and wchar_t, zero terminated string. Dynamic array of strings.
Create an auxiliary functions to protect your app from user's wrong input:
prevent entering chars instead of digits;
prevent entering more symbols than buffer capacity;
be ready for extra-large text input
How many times a given word present in a sentence?
User enters any number of sentences, application parses them, creates array of words from those sentences, counts number ot words, finds the longest and the shortest, sorts words by length and alphabetically.
Create "scrolling text string" app with option to suspend the cycle and update the content.
Advanced: Implement word-wrap algorithm.
Operators &, |, ^, ~, !, . -
Store in one integer variable four numbers from different ranges (0-5, 0-100, 10-60, 100- 40000).
Show binary representation of integer value
What is the biggest number can be stored in 1 byte?
Raise 2 to the power of 200.
List all logical drives of PC.
Encrypt and decrypt entered text.
Structures, enumerations, unions, bit fields:
What are user defined types. Differences between С and С++. First acquaintance with object-oriented programming.
Universal storage for every data type.
enum as compact declaration of related constants.
How to use unions to send and receive data any type.
Develop app "Students" to store and process personal data. The "Student" structure (data store) have to have following fields: name, surname, age, 5 marks (array), average mark. Implement simple operations with array of objects: search, sort, add, delete, edit. Create an algorithm of automatic initialization of array of structures (including names). You will enter array size from keyboard. Advanced task: sort and show data using pointers to structures, not objects itself.
How and where must be defined critical restrictions, constants.
How to include a compilation units from the same or different places, preventing from including a file several times.
Memory classes: extern, static, register, auto.
Static variables in functions and files.
Conditional compilation. Cross platform development.
Using # and ## operators in debug.
Macros: how to write a macro, pro and contra, and how to write convenient unit tests.
Create several *.h and *.cpp files and link them correctly.
Write a macro for performance evaluation of any statement.
The role of operating system, drivers and application in IO operations, references accounting, file operation modes.
What types of file related errors should be checked in production application.
Read, write and positioning operations. File size and format. Buffered output.
Differences between text and binary file opening modes. Which one should be used.
How to explore drives content and directories.
How to copy a big file.
Write to file encrypted data of any format. Read it, decrypt and show.
Create an app like reminder (diary, organizer). Description: The user enters some information and sets the time to remind about it. Once user launches this app, it checks the current date and time, looks through all records stored in a file. If there are something to remind at this time it displays a reminder message.
Simple file manager that can search and display the contents of every file (as is, without recognition of file format), and edit certain files. The student should develop his own file format for data storage and processing - a big array of structures 'Student' (see description above in practice section of the Structures).
Advanced complexity: Add field 'experience' to 'Student' structure (an array of characters in heap) and its length. Not all students have the experience, it should complicate file format.
The program must have a user-friendly interface and operate in two modes:
Create a file and find it in file system.
open, read, add or delete record, edit it, sort the data, based on their various criteria specified by the user.
Working in any mode, the user should be able to see the context menu. App must be protected from any user errors and not have any kind of memory leaks (heap memory, descriptors).
Course duration: 120 hours
Usage of the function pointers as search and comparison criteria, which can be passed as arguments to search or sort algorithms. Predicates.
Adapting your functionality to existing interface, for example: sort any arrays using qsort_s function. Callback functions, typedef.
How to extend functionality of your program without recompiling it. Cost of extra QA work.
Sort 'students' (see base course practice) by several criteria received at runtime.
Rewrite 'Calculator' app using array of function pointers.
Type deducing, typecast and function arguments, template function overloading.
Develop an app that sorts arrays of ints, chars and doubles using template functions.
Functions with variable (undefined) number of parameters:
The role of the first parameter, format specifiers, VA_LIST.
Develop a “mini printf” function.
Classes (base concepts):
Philosophy of class design and usage.
Constructors, destructors, overloaded constructors, class interface as a set of rules to work with him...
How to trace all calls to class functions in program.
Default class function functionalities and how to disable it.
Composition: aggregation and acquaintance, an interaction diagram, UML.
Initialization rule. How to work with resources. this, public, private.
A preprocessor #ifndef and compiler-dependent #pragma directives. What is a c++ standard; Class A has object of B class, but class B has a pointer to A - how to resolve this. Friends: How a function or class can become a friends to another class. Relations between 'friends'.
Develop Array and Line classes.
Another tool: class BackUp, that can be used by any client to safely rewrite any file, and safely retrieve a data (a proxy between a client and a file);
Copy constructor and operator overloading:
When do you need these tools? Shallow and deep copy.
How to copy an object that has another object inside.
Built-in and user defined data types. Operator overloading rules.
Overloading of +, =,