What is the difference between class and object?
Answer Posted / johncz
Class is a template for the custom type that can be used as
variable. It defines types of data that class contains and
the set of functions to manipulate those data types. It is
just a recipe to be used when class is instantiated.
Object is an entity created using class template. Such an
object occupies computer’s memory. Each object of the class
is independent entity.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
What is inheritance in simple words?
Why interface is used?
They started with the brief introduction followed by few basic C++ questions on polumorphism, inheritance and then virtual functions. What is polymorphims? How you will access polymorphic functions in C? How virtual function mechanism works?
Why is object oriented programming so hard?
any one please tell me the purpose of operator overloading
What are different types of JVM's? for example we use dalvik jvm for android then what about the remaining operating systems?
Is abstract thinking intelligence?
Why do we use polymorphism?
What is difference between oop and pop?
Can we define a class within the interface?
Which method cannot be overridden?
What is interface? When and where is it used?
#include
What is the real life example of polymorphism?
What is class encapsulation?