Advertisements
Advertisements
Question
Define an object with an example.
Definition
Solution
It is a unique entity having some characteristics and behaviours. It is known as the 'Instance of a Class'.
Example: If we consider the class "Fruits," then different varieties of fruits such as banana, apple, and pear are objects in the category "Fruits." Each fruit belongs to the class "Fruits," which has comparable behaviours and characteristics.
shaalaa.com
Is there an error in this question or solution?
Chapter 1.02: Elementary Concept of Objects and Classes - EXERCISES [Page 16]