Examveda
Examveda

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

D. Inheriting from multiple classes

Answer: Option C

Solution(By Examveda Team)

Encapsulation involves hiding the internal implementation details of an object and exposing a controlled interface.

This Question Belongs to Python Program >> Advanced OOP Concepts

Join The Discussion

Related Questions on Advanced OOP Concepts

What is inheritance in OOP?

A. Creating new objects from existing ones

B. Allowing objects to share attributes and methods

C. Restricting access to object attributes

D. Converting classes into objects