Question Bank
3705 approved questions from the community
What are the three core characteristics of an object?
What is multilevel inheritance?
What is the difference between aggregation and composition?
What is the Liskov Substitution Principle (LSP)?
What is hybrid inheritance?
Objects have identity, state, and behavior.
What does 'has-a' relationship signify in OOP?
What is the Single Responsibility Principle (SRP) in relation to cohesion?
What is a mixin in object-oriented programming?
A constructor can have a return type.
Inheritance promotes code reuse by allowing classes to acquire attributes and behaviors from parent classes.
Which of the following are purposes of destructors in OOP? (Select all that apply)
Which access specifier makes class members accessible within the class and its subclasses?
Which access specifier makes class members globally accessible to all classes?
What type of polymorphism is method overriding?
What relationship does composition establish between classes?
Which of the following are access specifiers commonly used in OOP? (Select all that apply)
What relationship does inheritance establish between classes?
What is the primary purpose of getters and setters in encapsulation?
Which access specifier makes class members accessible only within the defining class?