★ Must-know
📌 C++ combines near-assembly performance, manual memory control, object-oriented programming, generic programming, and procedural programming.
Further detail
C++ performance and control → systems, games, embedded software
★ Must-know
Further detail
The listed programming paradigms are:
C++ was introduced in 1985 after C in 1972, and Python and Java were introduced in 1991 and 1995 respectively.
Machine → Assembly → C/C++ → Java/Python
★ Must-know
Further detail
Problem definition identifies requirements, inputs, outputs, and constraints and produces a problem statement.
Algorithm design uses flowcharts and pseudocode to produce an algorithm before coding begins.
Define → Design → Code → Test → Document
★ Must-know
📌 A linker combines object files, resolves external references, and creates an executable, whereas a loader places the executable in memory and starts it.
Further detail
📌 Static linking copies libraries into the executable, whereas dynamic linking loads libraries at runtime and requires DLL or .so files.
Source → Compiler → Object files → Linker → Executable → Loader
★ Must-know
📌 A local variable is declared inside a function or block, whereas a global variable is declared outside all functions.
Further detail
📌 Procedural programming focuses on functions and separates data from functions, whereas object-oriented programming combines data and methods in objects.
EIPA: Encapsulation, Inheritance, Polymorphism, Abstraction
★ Must-know
📌 The dot operator accesses members through an object, whereas the arrow operator accesses members through a pointer to an object and is equivalent to (*pointer).member.
📌 Objects allocated on the stack are destroyed automatically, whereas objects allocated on the heap with new require a matching delete to prevent memory leaks.
Further detail
📌 A member function defined inside a class is inline by default, whereas a member function defined outside the class separates its interface from its implementation using the scope-resolution operator.
Class is the blueprint; object is the memory-resident instance
Public members are accessible from inside the class, derived classes, and outside the class.
Protected members are accessible inside their class and derived classes but not from outside the class.
Private members are accessible only inside their class, and the default access specifier in a class is private while the default access specifier in a struct is public.
public: everywhere; protected: class and children; private: class only
Access Specifier Visibility
| Specifier | Inside class | Derived class | Outside class |
|---|---|---|---|
| public | Yes | Yes | Yes |
| protected | Yes | Yes | No |
| private | Yes | No | No |
Test your knowledge on Introduction to C++ and OOP with 23 multiple-choice questions with detailed corrections.
1. Who created C++ at Bell Labs in 1985 as an extension of C with object-oriented features?
2. Which combination best characterizes C++ as a programming language?
Memorize the key concepts of Introduction to C++ and OOP with 48 interactive flashcards.
Who created C++ and when?
Bjarne Stroustrup created C++ in 1985.
Where was C++ created?
At Bell Labs.
What programming paradigms does C++ combine?
Object-oriented, generic, and procedural programming.
Import your course and AI generates sheets, quizzes and flashcards in 30 seconds.
Sheet generator