Question

Briefly explain the terms used in object-oriented programming with examples. NO COPY AND PASTE PLEASE USE...

Briefly explain the terms used in object-oriented programming with examples.

NO COPY AND PASTE PLEASE USE UR OWN WORDS

0 0
Add a comment Improve this question Transcribed image text
Answer #1

By definition we can say that OOP is modular approach which allows data to be applied in a stipulated programming area.

In simple words the the entire problem is simply divided into entities known as objects.Object is given more stress than function in OOP.

Basic Terms in OOP

1.OBJECT: Objects are nothing but uniquely identifiable entities that has it on data functions i.e characteristics or behaviour.

Say for example consider an object called Book. It has characteristics such as it has pages, useful information, etc where as it has functions or behaviours like to provide knowledge, entertainment purpose etc.

In developing a program for data base management of students of a college the objects are students with data like age marks etc and function associated with them are calculation of average marks, rank etc.

2.CLASS: They are set of similar objects where each objects posses same behaviour and function defined in class.

Eg: In above example if book was the object then library would be the class.

If student was an object then obviously departments(like Physics , etc )would be the class.

3.DATA ABSTRACTION: It is the act of representation of essential features without representation of the background details.

Eg: Consider the calculator you use. You will be able to perform several mathematical operations in it. Only its functions and data are available to user. No details of what is happening inside is represented while performing an operation.

4.Encapsulation:The wrapping up of data and functions into single unit is called Encapsulation.

Eg: The functions like addition ,subtraction ,multiplications ,division are encapsulated into a single unit called calculator.

5.Inheritance:It is process by which objects of one class can link and share common properties of other class.

For example I have two class one is a calculator class and another is Salary calculation class. This salary class need some properties like addition to add salary etc. So instead of again redefining we can derive it from calculator class.

6.Polymorphism: It is the process of using a function for more than one purpose.

The function Area can be used to calculate area of square with some suitable modification and realised by different inputs can also be used to calculate areas of rectangle ,circle etc.

Add a comment
Know the answer?
Add Answer to:
Briefly explain the terms used in object-oriented programming with examples. NO COPY AND PASTE PLEASE USE...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT