Computer Applications
Which of the Object Oriented programming principles explain the following illustrations? Justify.
(a) The variables and methods are put together in a Class.

(b) A man withdrawing money from ATM.

OOP Intro Java
39 Likes
Answer
(a) Encapsulation is illustrated in the given picture. Wrapping of data and functions of an object as a unit (class) that can be used together in a specific operation is known as Encapsulation. In the picture, the variables and methods are being encapsulated in a class.
(b) The principle of Data abstraction is illustrated here as the man withdraws money from the ATM using the withdraw option. He knows the essential features of the ATM machine such as withdrawing money, without knowing the complex background details of how the ATM machine is operating to provide money to him.
Answered By
22 Likes
Related Questions
What is meant by Data Hiding?
Give two differences between Data Hiding and Encapsulation.
'Encapsulation reduces the complexity and makes the system easier'. Explain this statement with a real world example.
Give two differences between Procedure Oriented Programming languages and Object Oriented Programming languages.