What does a C++ class define?
A class defines a user-defined type, including its representation, behavior, and interface.
Study 09 Introduction to Object-Oriented Programming with 12 free online flashcards. Review key terms, definitions, and concepts with this interactive flashcard deck.
What does a C++ class define?
A class defines a user-defined type, including its representation, behavior, and interface.
What is an object in OOP?
An object is an instance of a class: a concrete value that combines state with operations on that state.
What is a class invariant?
An invariant is a condition that should remain true for every valid object, such as a bank balance that cannot be changed through unrestricted outside access.
What does abstraction mean in OOP?
Abstraction exposes an object’s essential operations while hiding implementation details that callers do not need to know.
What does `= 0` mean on a virtual function?
A pure virtual function is declared with `= 0`; a class containing one is abstract and cannot be instantiated directly.
What is encapsulation?
Encapsulation combines data with the operations that manage it and controls access to the internal representation.
Who can access a C++ `private` member?
A `private` member is accessible only to the class’s members and permitted friends; outside code must use the public interface.
What are C++'s default member access levels?
Members of a `class` are `private` by default, while members of a `struct` are `public` by default.
What relationship does composition model?
Composition builds a class by storing objects of other classes as members; it expresses a “has-a” relationship.
When should inheritance be used?
Inheritance defines a new class in terms of an existing base class and can express a specialized, substitutable form of that base.
What does `override` verify in C++?
The `override` specifier asks the compiler to verify that a derived member actually overrides a virtual base member.
What is dynamic dispatch?
Dynamic dispatch selects the implementation at runtime based on the concrete object, even when called through a base reference or pointer.
A 14-question medium-difficulty quiz on Boolean algebra, logic gates, truth tables, and combinational circuits.
A focused set of flashcards covering Python variables, data types, expressions, control flow, functions, input, output, and common programming practices.
Learn how Boolean expressions, logical operators, and conditional structures let programs make reliable decisions, including how to handle boundaries, branch order, and testing.
Learn how computer memory stores and addresses information, how RAM and ROM differ, and how caches and the memory hierarchy balance speed, capacity, and cost.
A progressive guide to tree structure, binary-tree traversals, binary search tree operations, deletion, balancing, and the way tree height determines time and space costs.
A practical guide to integrating problem definition, data representation, modular programming, algorithms, complexity analysis, testing, correctness, and ethical evaluation into a responsible computer science capstone.
Reviews how interrupts support event handling and multitasking, and how Linux system calls use the RISC-V `ecall` instruction and register conventions.
This quiz covers process management, context switching and scheduling, multitasking, traps and interrupts, and RISC-V privilege transitions.
A quiz on operating-system system calls, including privileged-operation requests, process creation and execution with fork, exec, and waitpid, and signal handling.