07/01/25 ----------- Q)What are the differences between POP and OOP? POP OOP *************************************** 1)function(procedure) object is the fundamental unit. is the base unit of the application. 2)data and code that acts upon organised data are not properly organised. 3)How to process data is given data and code that acts importance. But data is given upon data are given second class status. importance. 4)data is freely flowing data doesnot flow freely. in the entire application. data is made available to eligible code only. 5) data is not secure. secure 6)can't handle complexity handles 7)Real world entities can be modelled. can't be modelled properly as data and code are treated as two different entities. *********************************************************** Q)What is encapsulation? =>Combining data and eligible code into a single unit is nothing but encapsulation. (wrapping of data and code) Note:- Encapsulation overcomes the limitations of POP Q)What is a class? =>Programmatical means of implementing encapsulation is nothing but a class. =>A class is a user defined data type. =>Blue Print/Plan of an object is nothing but a class. =>A class is an encapsulated unit. Q)What is an object? =>An instance of a class is nothing but an object. =>An object is a fundamental data storage area of an object oriented application. =>An object can be treated as a software bundle that holds application's data and code to process that data associated with it. =>An object is an encapsulated unit. =>Physical realisation of a class is nothing but an object.