What is encapsulation in Python?
Correct answer
A. Bundling data and methods and restricting direct access
6 views
A. Bundling data and methods and restricting direct access
6 views
Encapsulation groups data with the code that operates on it and controls access.
Asked in: Python Interview OOP
https://docs.python.org/3/tutorial/classes.htmlNot sure why the answer is A? Ask here and get an explanation.