Friday, June 20, 2014

OOPs concepts

Q:- What is Object oriented approach ?

Ans:- OOPs (Object oriented programming) is a technique for organizing our program/software as a group of different types of objects (real world entities like chair etc.)

Elements of object oriented approach :-

  • attributes :- Attribute is data value held by an entity.
  • function :- Function describe the behavior of the object.
  • objects :- Object is a real world entity.
  • classes :- Class refer to a group of similar objects.

Characteristics of Object-oriented Approach :-

  • Data Abstraction :- Data Abstraction refer to providing essential features without including background details.
  • Encapsulation :-  The property of binding the member data and member function in a single unit is called encapsulation.
  • Inheritance :- Inheritance is a mechanism of sharing attributes and operations among classes.
  • Polymorphism :- Polymorphism means that the same operation name may behave differently on different classes.

Advantages of Object oriented programming :-

  1. Each entity modified, reuse and upgrade easily.
  2. Easily relate one entity with another.
  3. Add new function and behavior easily.
  4. Add new entity.
  5. Increase Protection and Security by providing Data hiding.
  6. Simulate with real world.

No comments:

Post a Comment