Difficulty: Easy
Correct Answer: Encapsulation, abstraction, inheritance, and polymorphism
Explanation:
Introduction / Context:
Object oriented programming (OOP) is a major paradigm supported by C++. Understanding its core concepts is essential for designing classes, building reusable libraries, and answering interview questions confidently. Many entry level questions simply ask candidates to list or explain the basic concepts of OOP that C++ supports. This question focuses on naming those key ideas rather than going into low level implementation details.
Given Data / Assumptions:
Concept / Approach:
The four widely accepted core concepts of object oriented programming are encapsulation, abstraction, inheritance, and polymorphism. Encapsulation means bundling data and functions that operate on that data inside a class. Abstraction means exposing only the essential features of an object while hiding implementation details. Inheritance allows one class to derive from another, reusing and extending behaviour. Polymorphism allows different classes to be treated through a common interface, with virtual functions enabling different behaviour at runtime. The correct option must group these four concepts together.
Step-by-Step Solution:
Step 1: Recall that any standard C++ OOP textbook introduces encapsulation, abstraction, inheritance, and polymorphism as the basic pillars of OOP.
Step 2: Examine option (a), which lists exactly these four concepts in one sentence.
Step 3: Compare option (b), which lists phases of program translation and execution rather than OOP concepts.
Step 4: Check option (c), which mentions purely operating system concepts like paging and deadlock that are unrelated to C++ OOP.
Step 5: Look at option (d), which lists networking and data processing concepts, not OOP principles.
Step 6: Conclude that option (a) is clearly the correct answer.
Verification / Alternative check:
Another way to verify is to think of how C++ implements these concepts in practical code. Encapsulation uses private, protected, and public members. Abstraction uses abstract base classes and pure virtual functions. Inheritance uses the colon syntax with public, protected, or private inheritance. Polymorphism is achieved via virtual functions and dynamic binding. These examples align with the list in option (a), confirming that it correctly identifies the core OOP concepts in C++.
Why Other Options Are Wrong:
Option (b) is wrong because tokenisation, compilation, linking, and loading describe the build and execution pipeline, not OOP. Option (c) is incorrect because it contains memory management and scheduling terms from operating systems. Option (d) is unrelated to OOP, focusing instead on data transmission and networking ideas such as encryption and routing.
Common Pitfalls:
Some candidates confuse abstraction and encapsulation or treat them as identical concepts. While they are related, abstraction is about focusing on what an object does, while encapsulation is about how state and behaviour are wrapped and protected. Another pitfall is to list additional items like association and aggregation without naming the basic four concepts first. For exam style questions, it is important to start with the canonical set: encapsulation, abstraction, inheritance, and polymorphism.
Final Answer:
Encapsulation, abstraction, inheritance, and polymorphism.
Discussion & Comments