Vidyalelo
Python · Q1

Advanced OOP Concepts

Programming · Python · question 1

Q1

What is encapsulation in object-oriented programming (OOP)?

A.
Exposing internal details of an object
B.
Grouping data and methods into a single unit
C.
Hiding data and methods within an object
Answer
D.
Inheriting from multiple classes

Answer: Option C

Solution

Answer: Option C
Solution:
Encapsulation involves hiding the internal implementation details of an object and exposing a controlled interface.