+ 2
What is the meaning of the sentence " OBJECT IS AN INSTANCE OF A CLASS" ???
Please Explain !!
3 Answers
+ 6
It belongs to a class (and represents class)
+ 5
Hi!
So, for example. You have CLASS Cat, that shows all behavior and attributes of that CLASS. And you have Cat named Boris. Boris - exact OBJECT of CLASS Cat, because it has own age, color, energy and so on.
For conclusion, CLASS describes structure of each OBJECT => OBJECT = INSTANCE OF CLASS
+ 3
lets go one by one
Instance means derived from.
Assume "Human is a class" and Prashant is an object derived from the class with the properties of the Human : Class.
Another example
Animal is a class with properties, walks on 4 legs, 5 sense, eats grass etc., then Girafee is an Object derived from Animal Class.
Hope this helps.